[ Operating System | The ECLiPSe Built-In Predicates | Reference Manual | Alphabetic Index ]

alarm(+Clock)

The operating system will send the signal 14 to the ECLiPSe system Clock seconds after the command was entered.
Clock
Integer

Description

Used to send the signal 14 (SIGALRM) to the ECLiPSe system Clock seconds after the alarm/1 command is entered. If there is already a pending alarm, its clock is merely reset, i.e. there cannot be multiple alarm requests.

If Clock is 0, any pending alarm is cancelled. If Clock is negative, it is nevertheless interpreted as an unsigned integer.

Modes and Determinism

Exceptions

(4) instantiation fault
Clock is not instantiated.
(5) type error
Clock is not an integer.

Examples

Success:
      [eclipse]: alarm(1).
      yes.
      [eclipse]: Signal 14         % 1 second later

Error:
      alarm(I).                    (Error 4).
      alarm(2.0).                  (Error 5).



See Also

sleep / 1