![]() | Library Documentation | Structures | Signatures | Identifiers | Packages | About |
POSIX_PROCESS (basis)POSIX process operations.
The structure Posix.Process describes the primitive POSIX operations dealing with processes, as described in Section 3 of the POSIX standard 1003.1,1996.signature POSIX_PROCESS =
sig
eqtype signal
eqtype pid
val wordToPid : SysWord.word -> pid
val pidToWord : pid -> SysWord.word
val fork : unit -> pid option
val exec : string * string list -> 'a
val exece : string * string list * string list -> 'a
val execp : string * string list -> 'a
datatype waitpid_arg
= W_ANY_CHILD
| W_CHILD of pid
| W_SAME_GROUP
| W_GROUP of pid
datatype exit_status
= W_EXITED
| W_EXITSTATUS of Word8.word
| W_SIGNALED of signal
| W_STOPPED of signal
val fromStatus : OS.Process.status -> exit_status
structure W : sig
include BIT_FLAGS
val untraced : flags
end
val wait : unit -> pid * exit_status
val waitpid : waitpid_arg * W.flags list -> pid * exit_status
val waitpid_nh : waitpid_arg * W.flags list -> (pid * exit_status) option
val exit : Word8.word -> 'a
datatype killpid_arg
= K_PROC of pid
| K_SAME_GROUP
| K_GROUP of pid
val kill : killpid_arg * signal -> unit
val alarm : Time.time -> Time.time
val pause : unit -> unit
val sleep : Time.time -> Time.time
end
W_ANY_CHILD : Any child process
W_CHILD pid : The child process with the given pid
W_SAME_GROUP : Any child process in the same process group as the
calling process
W_GROUP pid : Any child process whose process group ID is given
by pid.
the status of child processes that are stopped.
K_PROC pid : The process with ID pid.
K_SAME_GROUP : All processes in the same process group as the
calling process.
K_GROUP pid : All processes in the process group specified by
pid.