sig
type file_descr
val to_file_descr :
[ `File of Uwt.file
| `Pipe of Uwt.Pipe.t
| `Tcp of Uwt.Tcp.t
| `Udp of Uwt.Udp.t ] -> Uwt_compat.Lwt_unix.file_descr
val from_file_descr :
Uwt_compat.Lwt_unix.file_descr ->
[ `File of Uwt.file
| `Pipe of Uwt.Pipe.t
| `Tcp of Uwt.Tcp.t
| `Udp of Uwt.Udp.t ]
type dir_handle
type process_status =
Unix.process_status =
WEXITED of int
| WSIGNALED of int
| WSTOPPED of int
type wait_flag = Unix.wait_flag = WNOHANG | WUNTRACED
type file_perm = Unix.file_perm
type open_flag =
Unix.open_flag =
O_RDONLY
| O_WRONLY
| O_RDWR
| O_NONBLOCK
| O_APPEND
| O_CREAT
| O_TRUNC
| O_EXCL
| O_NOCTTY
| O_DSYNC
| O_SYNC
| O_RSYNC
| O_SHARE_DELETE
| O_CLOEXEC
| O_KEEPEXEC
type seek_command = Unix.seek_command = SEEK_SET | SEEK_CUR | SEEK_END
type file_kind = Unix.file_kind
type stats =
Unix.stats = {
st_dev : int;
st_ino : int;
st_kind : Uwt_compat.Lwt_unix.file_kind;
st_perm : Uwt_compat.Lwt_unix.file_perm;
st_nlink : int;
st_uid : int;
st_gid : int;
st_rdev : int;
st_size : int;
st_atime : float;
st_mtime : float;
st_ctime : float;
}
type access_permission = Unix.access_permission = R_OK | W_OK | X_OK | F_OK
type inet_addr = Unix.inet_addr
type socket_domain = Unix.socket_domain = PF_UNIX | PF_INET | PF_INET6
type socket_type =
Unix.socket_type =
SOCK_STREAM
| SOCK_DGRAM
| SOCK_RAW
| SOCK_SEQPACKET
type sockaddr =
Unix.sockaddr =
ADDR_UNIX of string
| ADDR_INET of Uwt_compat.Lwt_unix.inet_addr * int
type shutdown_command =
Unix.shutdown_command =
SHUTDOWN_RECEIVE
| SHUTDOWN_SEND
| SHUTDOWN_ALL
type msg_flag = Unix.msg_flag = MSG_OOB | MSG_DONTROUTE | MSG_PEEK
type socket_bool_option =
Unix.socket_bool_option =
SO_DEBUG
| SO_BROADCAST
| SO_REUSEADDR
| SO_KEEPALIVE
| SO_DONTROUTE
| SO_OOBINLINE
| SO_ACCEPTCONN
| TCP_NODELAY
| IPV6_ONLY
type socket_int_option =
Unix.socket_int_option =
SO_SNDBUF
| SO_RCVBUF
| SO_ERROR
| SO_TYPE
| SO_RCVLOWAT
| SO_SNDLOWAT
type socket_optint_option = Unix.socket_optint_option = SO_LINGER
type socket_float_option =
Unix.socket_float_option =
SO_RCVTIMEO
| SO_SNDTIMEO
type host_entry =
Unix.host_entry = {
h_name : string;
h_aliases : string array;
h_addrtype : Uwt_compat.Lwt_unix.socket_domain;
h_addr_list : Uwt_compat.Lwt_unix.inet_addr array;
}
type protocol_entry =
Unix.protocol_entry = {
p_name : string;
p_aliases : string array;
p_proto : int;
}
type service_entry =
Unix.service_entry = {
s_name : string;
s_aliases : string array;
s_port : int;
s_proto : string;
}
type addr_info =
Unix.addr_info = {
ai_family : Uwt_compat.Lwt_unix.socket_domain;
ai_socktype : Uwt_compat.Lwt_unix.socket_type;
ai_protocol : int;
ai_addr : Uwt_compat.Lwt_unix.sockaddr;
ai_canonname : string;
}
type getaddrinfo_option =
Unix.getaddrinfo_option =
AI_FAMILY of Uwt_compat.Lwt_unix.socket_domain
| AI_SOCKTYPE of Uwt_compat.Lwt_unix.socket_type
| AI_PROTOCOL of int
| AI_NUMERICHOST
| AI_CANONNAME
| AI_PASSIVE
type name_info =
Unix.name_info = {
ni_hostname : string;
ni_service : string;
}
type getnameinfo_option =
Unix.getnameinfo_option =
NI_NOFQDN
| NI_NUMERICHOST
| NI_NAMEREQD
| NI_NUMERICSERV
| NI_DGRAM
type terminal_io =
Unix.terminal_io = {
mutable c_ignbrk : bool;
mutable c_brkint : bool;
mutable c_ignpar : bool;
mutable c_parmrk : bool;
mutable c_inpck : bool;
mutable c_istrip : bool;
mutable c_inlcr : bool;
mutable c_igncr : bool;
mutable c_icrnl : bool;
mutable c_ixon : bool;
mutable c_ixoff : bool;
mutable c_opost : bool;
mutable c_obaud : int;
mutable c_ibaud : int;
mutable c_csize : int;
mutable c_cstopb : int;
mutable c_cread : bool;
mutable c_parenb : bool;
mutable c_parodd : bool;
mutable c_hupcl : bool;
mutable c_clocal : bool;
mutable c_isig : bool;
mutable c_icanon : bool;
mutable c_noflsh : bool;
mutable c_echo : bool;
mutable c_echoe : bool;
mutable c_echok : bool;
mutable c_echonl : bool;
mutable c_vintr : char;
mutable c_vquit : char;
mutable c_verase : char;
mutable c_vkill : char;
mutable c_veof : char;
mutable c_veol : char;
mutable c_vmin : int;
mutable c_vtime : int;
mutable c_vstart : char;
mutable c_vstop : char;
}
type setattr_when = Unix.setattr_when = TCSANOW | TCSADRAIN | TCSAFLUSH
type flush_queue = Unix.flush_queue = TCIFLUSH | TCOFLUSH | TCIOFLUSH
val handle_unix_error : ('a -> 'b Lwt.t) -> 'a -> 'b Lwt.t
val sleep : float -> unit Lwt.t
val yield : unit -> unit Lwt.t
val auto_yield : float -> unit -> unit Lwt.t
exception Timeout
val timeout : float -> 'a Lwt.t
val with_timeout : float -> (unit -> 'a Lwt.t) -> 'a Lwt.t
val stdin : Uwt_compat.Lwt_unix.file_descr
val stdout : Uwt_compat.Lwt_unix.file_descr
val stderr : Uwt_compat.Lwt_unix.file_descr
val openfile :
string ->
Unix.open_flag list ->
Uwt_compat.Lwt_unix.file_perm -> Uwt_compat.Lwt_unix.file_descr Lwt.t
val close : Uwt_compat.Lwt_unix.file_descr -> unit Lwt.t
val read :
Uwt_compat.Lwt_unix.file_descr -> bytes -> int -> int -> int Lwt.t
val write :
Uwt_compat.Lwt_unix.file_descr -> bytes -> int -> int -> int Lwt.t
val write_string :
Uwt_compat.Lwt_unix.file_descr -> string -> int -> int -> int Lwt.t
val lseek :
Uwt_compat.Lwt_unix.file_descr -> int -> Unix.seek_command -> int Lwt.t
val truncate : string -> int -> unit Lwt.t
val ftruncate : Uwt_compat.Lwt_unix.file_descr -> int -> unit Lwt.t
val fsync : Uwt_compat.Lwt_unix.file_descr -> unit Lwt.t
val fdatasync : Uwt_compat.Lwt_unix.file_descr -> unit Lwt.t
val stat : string -> Unix.stats Lwt.t
val lstat : string -> Unix.stats Lwt.t
val fstat : Uwt_compat.Lwt_unix.file_descr -> Unix.stats Lwt.t
val isatty : Uwt_compat.Lwt_unix.file_descr -> bool Lwt.t
val file_exists : string -> bool Lwt.t
module LargeFile :
sig
type stats =
Unix.LargeFile.stats = {
st_dev : int;
st_ino : int;
st_kind : Uwt_compat.Lwt_unix.file_kind;
st_perm : Uwt_compat.Lwt_unix.file_perm;
st_nlink : int;
st_uid : int;
st_gid : int;
st_rdev : int;
st_size : int64;
st_atime : float;
st_mtime : float;
st_ctime : float;
}
val stat : string -> Unix.LargeFile.stats Lwt.t
val lstat : string -> Unix.LargeFile.stats Lwt.t
val fstat :
Uwt_compat.Lwt_unix.file_descr -> Unix.LargeFile.stats Lwt.t
val lseek :
Uwt_compat.Lwt_unix.file_descr ->
int64 -> Unix.seek_command -> int Lwt.t
val truncate : string -> int64 -> unit Lwt.t
val ftruncate : Uwt_compat.Lwt_unix.file_descr -> int64 -> unit Lwt.t
val file_exists : string -> bool Lwt.t
end
val unlink : string -> unit Lwt.t
val rename : string -> string -> unit Lwt.t
val link : string -> string -> unit Lwt.t
val chmod : string -> Uwt_compat.Lwt_unix.file_perm -> unit Lwt.t
val fchmod :
Uwt_compat.Lwt_unix.file_descr ->
Uwt_compat.Lwt_unix.file_perm -> unit Lwt.t
val chown : string -> int -> int -> unit Lwt.t
val fchown : Uwt_compat.Lwt_unix.file_descr -> int -> int -> unit Lwt.t
val access : string -> Unix.access_permission list -> unit Lwt.t
val mkdir : string -> Uwt_compat.Lwt_unix.file_perm -> unit Lwt.t
val rmdir : string -> unit Lwt.t
val opendir : string -> Uwt_compat.Lwt_unix.dir_handle Lwt.t
val readdir : Uwt_compat.Lwt_unix.dir_handle -> string Lwt.t
val readdir_n : Uwt_compat.Lwt_unix.dir_handle -> int -> string array Lwt.t
val closedir : Uwt_compat.Lwt_unix.dir_handle -> unit Lwt.t
val files_of_directory : string -> string Lwt_stream.t
val symlink : string -> string -> unit Lwt.t
val readlink : string -> string Lwt.t
val getlogin : unit -> string Lwt.t
val getpwnam : string -> Unix.passwd_entry Lwt.t
val getgrnam : string -> Unix.group_entry Lwt.t
val getpwuid : int -> Unix.passwd_entry Lwt.t
val getgrgid : int -> Unix.group_entry Lwt.t
val chdir : string -> unit Lwt.t
val chroot : string -> unit Lwt.t
val getcwd : unit -> string Lwt.t
val gethostname : unit -> string Lwt.t
val gethostbyname : string -> Unix.host_entry Lwt.t
val gethostbyaddr : Unix.inet_addr -> Unix.host_entry Lwt.t
val getprotobyname : string -> Unix.protocol_entry Lwt.t
val getprotobynumber : int -> Unix.protocol_entry Lwt.t
val getservbyname : string -> string -> Unix.service_entry Lwt.t
val getservbyport : int -> string -> Unix.service_entry Lwt.t
val getaddrinfo :
string ->
string -> Unix.getaddrinfo_option list -> Unix.addr_info list Lwt.t
val getnameinfo :
Unix.sockaddr -> Unix.getnameinfo_option list -> Unix.name_info Lwt.t
val pipe :
unit -> Uwt_compat.Lwt_unix.file_descr * Uwt_compat.Lwt_unix.file_descr
val pipe_in : unit -> Uwt_compat.Lwt_unix.file_descr * Unix.file_descr
val pipe_out : unit -> Unix.file_descr * Uwt_compat.Lwt_unix.file_descr
val system : string -> Unix.process_status Lwt.t
val utimes : string -> float -> float -> unit Lwt.t
type signal_handler_id
val on_signal :
int -> (int -> unit) -> Uwt_compat.Lwt_unix.signal_handler_id
val on_signal_full :
int ->
(Uwt_compat.Lwt_unix.signal_handler_id -> int -> unit) ->
Uwt_compat.Lwt_unix.signal_handler_id
val disable_signal_handler : Uwt_compat.Lwt_unix.signal_handler_id -> unit
end