Warning: Reason support is experimental. We are looking for beta-tester and contributors.

Index of values

(<&>) [Lwt]

t <&> t' is the same as join [t; t']

(<?>) [Lwt]

t <?> t' is the same as choose [t; t']

Error a_api: exception Api.Error("\"(=|<)>>~[<<a_api|moduleLwt>>~]|<<divclass=\\\"odocwiki_info\\\"|<<spanclass=\\\"odocwiki_inlinecode\\\"|f~=~|~<m>>is<<spanclass=\\\"odocwiki_inlinecode\\\"|mapfm>>>>||@@class=\\\"odocwiki_index\\\"@@@<<a_apitext=\\\"(>>=)\\\"|valueLwt\" is not a valid module name")=) >> [Lwt]

t >>= f is an alternative notation for bind t f.

(>|=) [Lwt]

m >|= f is map f m

abort [Lwt_unix]

abort fd exn makes all current and further uses of the file descriptor fail with the given exception.

abort [Lwt_io]

abort ch abort current operations and close the channel immediatly.

abort [Lwt_ssl]
accept [Lwt_unix]

Wrapper for Unix.accept

accept [Lwt_read_line.​Control]

accept instance = send_command instance Command.Accept_line

accept_n [Lwt_unix]

accept_n fd count accepts up to count connection in one time.

access [Lwt_unix]

Wrapper for Unix.access

accum_s [Lwt_signal]
accum_s [Lwt_react.​S]
accum_s [Lwt_react.​E]
accum_s [Lwt_event]
add [Lwt_pqueue.​S]
add_entry [Lwt_read_line]

add_entry line history returns the history history plus line at the beginning.

add_hook [Lwt_switch]

add_hook switch f registers f so it will be called when Lwt_switch.​turn_off is invoked.

add_hook_or_exec [Lwt_switch]

add_hook_or_exec switch f is the same as Lwt_switch.​add_hook except that if the switch is already off, then f is called immediatly.

add_l [Lwt_sequence]

add_l x s adds x to the left of the sequence s

add_r [Lwt_sequence]

add_l x s adds x to the right of the sequence s

add_rule [Lwt_log]

add_rule pattern level adds a rule for sections logging levels.

all_input [Lwt_read_line.​Engine]

Returns the current complete user input.

always_notify [Lwt_signal]
always_notify [Lwt_event]
always_notify_p [Lwt_signal]
always_notify_p [Lwt_event]
always_notify_s [Lwt_signal]
always_notify_s [Lwt_event]
app_p [Lwt_react.​E]
app_p [Lwt_event]
app_s [Lwt_signal]
app_s [Lwt_react.​S]
app_s [Lwt_react.​E]
app_s [Lwt_event]
append [Lwt_stream]

append s1 s2 returns a stream which returns all elements of s1, then all elements of s2

append_rule [Lwt_log]

append_rule pattern level adds the given rule after all other rules.

async_method [Lwt_unix]

async_method () returns the async method used in the current thread.

async_method_key [Lwt_unix]

The key for storing the local async method.

at_exit [Lwt_main]

at_exit hook adds hook at the left of exit_hooks

atomic [Lwt_io]

atomic f transforms a sequence of io operations into one single atomic io operation.

atomic [Lwt_text]
auto_yield [Lwt_unix]

auto_yield timeout returns a function f which will yield every timeout seconds.

bg [Lwt_term]

bg col = Background col

bind [Lwt_unix]

Wrapper for Unix.bind

bind [Lwt_signal]
bind [Lwt_react.​S]

bind ?eq s f is initially f x where x is the current value of s.

bind [Lwt]

bind t f is a thread which first waits for the thread t to terminate and then, if the thread succeeds, behaves as the application of function f to the return value of t.

bind_s [Lwt_react.​S]

Same as Lwt_react.​S.​bind except that f returns a thread.

black [Lwt_term]
blank [Lwt_term]

A space with default color and styles

blink [Lwt_term]
blit [Lwt_bytes]

blit buf1 ofs1 buf2 ofs2 len copy len bytes from buf1 starting at offset ofs1 to buf2 starting at offset ofs2.

blit_bytes_string [Lwt_bytes]

Same as blit but the second buffer is a string instead of a byte array.

blit_string_bytes [Lwt_bytes]

Same as blit but the first buffer is a string instead of a byte array.

block [Lwt_io]

block ch size f pass to f the internal buffer and an offset.

blocking [Lwt_unix]

blocking fd returns whether fd is used in blocking or non-blocking mode.

blue [Lwt_term]
bold [Lwt_term]
broadcast [Lwt_log]

broadcast loggers is a logger which send messages to all the given loggers.

broadcast [Lwt_condition]

broadcast condvar value notifies all waiting threads.

buffer_size [Lwt_io]

Returns the size of the internal buffer.

buffered [Lwt_io]

buffered oc returns the number of bytes in the buffer

byte_channel [Lwt_text]

byte_channel ch returns the underlying byte channel of a text channel

byte_order [Lwt_sys]

The byte order used by the computer running the program.

cancel [Lwt]

cancel t cancels the threads t.

cancel_jobs [Lwt_unix]

cancel_jobs () make all pending jobs to fail with Lwt.​Canceled.

catch [Lwt]

catch t f is a thread that behaves as the thread t () if this thread succeeds.

change [Lwt_timeout]

changes the duration of a timeout.

channel [Lwt_log]

channel ?template ~close_mode ~channel () creates a logger from a channel.

chars_of_file [Lwt_io]

chars_of_file name returns a stream of all characters of the file with name name.

chars_of_file [Lwt_text]
chars_to_file [Lwt_io]

chars_to_file name chars writes all characters of chars to name

chars_to_file [Lwt_text]
chdir [Lwt_unix]

Wrapper for Unix.chdir

check [Lwt_switch]

check switch does nothing if switch is None or contains an switch that is currently on, and raise Lwt_switch.​Off otherwise.

check_descriptor [Lwt_unix]

check_descriptor fd raise an exception if fd is not in the state Open

chmod [Lwt_unix]

Wrapper for Unix.chmod

choose [Lwt_stream]

choose l creates an stream from a list of streams.

choose [Lwt]

choose l behaves as the first thread in l to terminate.

chown [Lwt_unix]

Wrapper for Unix.chown

chroot [Lwt_unix]

Wrapper for Unix.chroot

clear_close_on_exec [Lwt_unix]

Wrapper for Unix.clear_close_on_exec

clear_line [Lwt_term]

clear_line () clears the current line

clear_screen [Lwt_term]

clear_screen () clears the entire screen

clipboard [Lwt_read_line]

The global clipboard.

clone [Lwt_stream]

clone st clone the given stream.

close [Lwt_unix]

Close a file descriptor.

close [Lwt_log]

Close the given logger

close [Lwt_io]

close ch closes the given channel.

close [Lwt_text]

Close the underlying byte channel

close [Lwt_ssl]
close_in [Lwt_chan]
close_out [Lwt_chan]
closedir [Lwt_unix]

Wrapper for Unix.closedir

columns [Lwt_term]

Number of columns of the terminal

combine [Lwt_stream]

combine s1 s2 combine two streams.

compare [Lwt_pqueue.​OrderedType]
complete [Lwt_read_line]

complete ?suffix before word after words basic completion functions.

completion_mode [Lwt_top]

Return the current completion mode.

concat [Lwt_stream]

concat st returns the concatenation of all streams of st.

connect [Lwt_unix]

Wrapper for Unix.connect

control_mapping [Lwt_term]

Mapping from control key codes to character codes.

copy [Lwt_bytes]

copy buffer creates a copy of the given byte array.

create [Lwt_timeout]

create n f defines a new timeout with n seconds duration.

create [Lwt_throttle.​S]
create [Lwt_bytes]

Creates a new byte array of the given size.

create [Lwt_switch]

create () creates a new switch.

create [Lwt_stream]

create () returns a new stream and a push function

create [Lwt_sequence]

create () creates a new empty sequence

create [Lwt_pool]

create n f creates a new pool with at most n members.

create [Lwt_mvar]

create v creates a new mailbox variable containing value v.

create [Lwt_mutex]

create () creates a new mutex, which is initially unlocked

create [Lwt_condition]

create () creates a new condition variable.

create_empty [Lwt_mvar]

create () creates a new empty mailbox variable.

cyan [Lwt_term]

daemonize [Lwt_daemon]

Put the current running process into daemon mode.

debug [Lwt_log]
debug_f [Lwt_log]
decode_key [Lwt_term]

Decode a key.

default [Lwt_log]

The default logger.

default [Lwt_term]
default_async_method [Lwt_unix]

Returns the default async method.

default_buffer_size [Lwt_io]

Return the default size for buffers.

delay [Lwt_signal]
delay [Lwt_react.​E]

delay thread is an event which does not occurs until thread returns.

delay [Lwt_event]
detach [Lwt_preemptive]

detaches a computation to a preemptive thread.

diff_s [Lwt_signal]
diff_s [Lwt_react.​S]
diff_s [Lwt_react.​E]
diff_s [Lwt_event]
direct_access [Lwt_io]

direct_access ch f pass to f a Lwt_io.​direct_access structure.

disable [Lwt_signal]
disable [Lwt_event]
disable_signal_handler [Lwt_unix]

Stops receiving this signal

dispatch [Lwt_log]

dispatch f is a logger which dispatch logging instructions to different logger according to their level and/or section.

draw [Lwt_read_line.​Terminal]

draw ~column ?map_text ?bar ~render_state ~engine_state prompt () returns (text, state) where state is the new rendering state, and text is a text containing escape sequences.

dup [Lwt_unix]

Wrapper for Unix.dup

dup2 [Lwt_unix]

Wrapper for Unix.dup2

edition_state [Lwt_read_line.​Engine]

Returns the edition state of a state, whatever its mode is.

embed_socket [Lwt_ssl]
empty [Lwt_pqueue.​S]
encoding [Lwt_text]

encoding ch returns the character encoding of a channel.

engine_state [Lwt_read_line.​Control]

Return the engine state of the given state

enter_drawing_mode [Lwt_term]

Put the terminal into drawing mode

enter_iter_hooks [Lwt_main]

Functions that are called before the main iteration.

eprint [Lwt_io]
eprint [Lwt_text]
eprintc [Lwt_term]

Same as printc but prints on stderr.

eprintf [Lwt_io]
eprintf [Lwt_text]
eprintl [Lwt_io]
eprintl [Lwt_text]
eprintlc [Lwt_term]

Same as printlc but prints on stderr

eprintlf [Lwt_io]
eprintlf [Lwt_text]
erase [Lwt_read_line.​Terminal]

erase ~columns ~render_state () returns a text which will erase everything (the prompt, user input, completion, ...).

error [Lwt_log]
error_f [Lwt_log]
establish_server [Lwt_io]

establich_server ?buffer_size ?backlog sockaddr f creates a server which will listen for incomming connections.

exec [Lwt_process]

Executes the given command and returns its exit status.

execute_job [Lwt_unix]

execute_job ?async_method ~job ~get ~free starts job and wait for its termination.

exists_p [Lwt_list]
exists_s [Lwt_list]
exit_hooks [Lwt_main]

Sets of functions executed just before the program exit.

extract [Lwt_bytes]

extract buffer offset length creates a new byte array of length length and copy the length bytes of buffer at offset into it.

fail [Lwt]

fail e is a thread that fails with the exception e.

fake_event [Lwt_engine]

Event which does nothing when stopped.

fake_io [Lwt_engine]

Simulates activity on the given file descriptor.

fatal [Lwt_log]
fatal_f [Lwt_log]
fchmod [Lwt_unix]

Wrapper for Unix.fchmod

fchown [Lwt_unix]

Wrapper for Unix.fchown

fdatasync [Lwt_unix]

Synchronise all data (but not metadata) of the file descriptor with the disk.

fg [Lwt_term]

fg col = Foreground col

file [Lwt_log]

desf_file ?template ?mode ?perm ~file_name () creates an logger which will write messages to file_name.

file_length [Lwt_io]

Returns the length of a file

files_of_directory [Lwt_unix]

files_of_directory dir returns the stream of all files of dir.

fill [Lwt_bytes]

fill buffer offset length value puts value in all length bytes of buffer starting at offset offset.

filter [Lwt_stream]
filter_map [Lwt_stream]
filter_map_s [Lwt_stream]

filter_map f st filter and map st at the same time

filter_p [Lwt_react.​E]
filter_p [Lwt_event]
filter_p [Lwt_list]
filter_s [Lwt_signal]
filter_s [Lwt_react.​S]
filter_s [Lwt_react.​E]
filter_s [Lwt_event]
filter_s [Lwt_stream]

filter f st keeps only value x such that f x is true

filter_s [Lwt_list]
finalise [Lwt_gc]

finalise f x calls f x when x is garbage collected.

finalise_or_exit [Lwt_gc]

finalise_or_exit f x call f x when x is garbage collected or (exclusively) when the program exit.

finalize [Lwt]

finalize f g returns the same result as f () whether it fails or not.

find [Lwt_stream]
find_map [Lwt_stream]
find_map_s [Lwt_stream]

find f s find and map at the same time.

find_min [Lwt_pqueue.​S]
find_s [Lwt_stream]

find f s find an element in a stream.

find_s [Lwt_list]
flatten [Lwt_stream]

flatten st = map_list (fun l -> l) st

flush [Lwt_io]

flush oc performs all pending writes on oc

flush [Lwt_chan]
flush [Lwt_text]

Flush the underlying byte channel

flush_all [Lwt_io]

flush_all () flushes all open output channels

fmap_p [Lwt_react.​E]
fmap_p [Lwt_event]
fmap_s [Lwt_signal]
fmap_s [Lwt_react.​S]
fmap_s [Lwt_react.​E]
fmap_s [Lwt_event]
fold [Lwt_stream]
fold_l [Lwt_sequence]

fold_l f s is:

fold_l f s x = f en (... (f e2 (f e1 x)))

where e1, e2, ..., en are the elements of s

fold_left [Lwt_util]

Similar to List.fold_left.

fold_left_s [Lwt_list]
fold_r [Lwt_sequence]

fold_r f s is:

fold_r f s x = f e1 (f e2 (... (f en x)))

where e1, e2, ..., en are the elements of s

fold_right_s [Lwt_list]
fold_s [Lwt_signal]
fold_s [Lwt_react.​S]
fold_s [Lwt_react.​E]
fold_s [Lwt_event]
fold_s [Lwt_stream]

fold f s x fold_like function for streams.

for_all_p [Lwt_list]
for_all_s [Lwt_list]
fork [Lwt_unix]

fork () does the same as Unix.fork.

fprint [Lwt_io]
fprint [Lwt_text]
fprintf [Lwt_io]
fprintf [Lwt_text]
fprintl [Lwt_io]
fprintl [Lwt_text]
fprintlf [Lwt_io]
fprintlf [Lwt_text]
from [Lwt_react.​E]

from f creates an event which occurs each f () returns a value.

from [Lwt_event]
from [Lwt_stream]

from f creates an stream from the given input function.

fstat [Lwt_unix.​LargeFile]

Wrapper for Unix.LargeFile.fstat

fstat [Lwt_unix]

Wrapper for Unix.fstat

fsync [Lwt_unix]

Synchronise all data and metadata of the file descriptor with the disk.

ftruncate [Lwt_unix.​LargeFile]

Wrapper for Unix.LargeFile.ftruncate

ftruncate [Lwt_unix]

Wrapper for Unix.ftruncate

get [Lwt_engine]

get () returns the engine currently in use.

get [Lwt_bytes]

get buffer offset returns the byte at offset offset in buffer.

get [Lwt_term.​Draw]

get ~zone ~x ~y returns the point at relative position x and y.

get [Lwt_stream]

get st remove and returns the first element of the stream, if any.

get [Lwt_sequence]

Returns the contents of a node

get [Lwt]

get key returns the value associated with key in the current thread.

get_affinity [Lwt_unix]

get_affinity ?pid () returns the list of CPUs the process with pid pid is allowed to run on.

get_available [Lwt_stream]

get_available l returns all available elements of l without blocking

get_available_up_to [Lwt_stream]

get_available_up_to l n returns up to n elements of l without blocking

get_bounds [Lwt_preemptive]

get_bounds () returns the minimum and the maximum number of preemptive threads.

get_cpu [Lwt_unix]

get_cpu () returns the number of the CPU the current thread is running on.

get_credentials [Lwt_unix]

get_credentials fd returns credential informations from the given socket.

get_max_number_of_threads_queued [Lwt_preemptive]

Returns the size of the waiting queue, if no more threads are available

get_while [Lwt_stream]
get_while_s [Lwt_stream]

get_while f st returns the longest prefix of st where all elements satisfy f.

getaddrinfo [Lwt_unix]

Wrapper for Unix.getaddrinfo

getaddrinfo [Lwt_lib]

Cooperative getaddrinfo with cache (using Lwt_preemptive.detach)

getgrgid [Lwt_unix]

Wrapper for Unix.getgrgid

getgrnam [Lwt_unix]

Wrapper for Unix.getgrnam

gethostbyaddr [Lwt_unix]

Wrapper for Unix.gethostbyaddr

gethostbyname [Lwt_unix]

Wrapper for Unix.gethostbyname

gethostbyname [Lwt_lib]

Cooperative gethostbyname with cache (using Lwt_preemptive.detach)

gethostname [Lwt_unix]

Wrapper for Unix.gethostname

getlogin [Lwt_unix]

Wrapper for Unix.getlogin

getnameinfo [Lwt_unix]

Wrapper for Unix.getnameinfo

getnameinfo [Lwt_lib]

Cooperative getnameinfo with cache (using Lwt_preemptive.detach)

getpeername [Lwt_unix]

Wrapper for Unix.getpeername

getpeername [Lwt_ssl]
getprotobyname [Lwt_unix]

Wrapper for Unix.getprotobyname

getprotobynumber [Lwt_unix]

Wrapper for Unix.getprotobynumber

getpwnam [Lwt_unix]

Wrapper for Unix.getpwnam

getpwuid [Lwt_unix]

Wrapper for Unix.getpwuid

getservbyname [Lwt_unix]

Wrapper for Unix.getservbyname

getservbyport [Lwt_unix]

Wrapper for Unix.getservbyport

getsockname [Lwt_unix]

Wrapper for Unix.getsockname

getsockname [Lwt_ssl]
getsockopt [Lwt_unix]

Wrapper for Unix.getsockopt

getsockopt_error [Lwt_unix]

Wrapper for Unix.getsockopt_error

getsockopt_float [Lwt_unix]

Wrapper for Unix.getsockopt_float

getsockopt_int [Lwt_unix]

Wrapper for Unix.getsockopt_int

getsockopt_optint [Lwt_unix]

Wrapper for Unix.getsockopt_optint

goto_beginning_of_line [Lwt_term]

goto_beginning_of_line n put the cursor at the beginning of the nth previous line.

green [Lwt_term]

handle_unix_error [Lwt_unix]

Same as Unix.handle_unix_error but catches lwt-level exceptions

have [Lwt_sys]

Test whether the given feature is available on the current system.

height [Lwt_term.​Zone]
hexdump [Lwt_io]

hexdump oc str = hexdump_stream oc (Lwt_stream.of_string str)

hexdump [Lwt_text]
hexdump [Lwt_stream]

hexdump byte_stream returns a stream which is the same as the output of hexdump -C.

hexdump_stream [Lwt_io]

hexdump_stream oc byte_stream produces the same output as the command hexdump -C.

hexdump_stream [Lwt_text]
hidden [Lwt_term]
hide [Lwt_read_line.​Control]

Hides everything (prompt, user input, completion box) until Lwt_read_line.​Control.​show is called.

hide_cursor [Lwt_term]

hide_cursor () makes the cursor invisible

ignore_result [Lwt]

ignore_result t start the thread t and ignores its result value if the thread terminates sucessfully.

in_channel_of_descr [Lwt_chan]
in_channel_of_descr [Lwt_ssl]
info [Lwt_log]
info_f [Lwt_log]
init [Lwt_read_line.​Terminal]

Initial state

init [Lwt_read_line.​Engine]

init history return a initial state using the given history

init [Lwt_preemptive]

init min max log initialises this module.

inner [Lwt_term.​Zone]

inner zone returns the inner part of zone

input [Lwt_io]

input input mode representation

input [Lwt_chan]
input_binary_int [Lwt_chan]
input_char [Lwt_chan]
input_line [Lwt_chan]
input_value [Lwt_chan]
install [Lwt_glib]

Install the Glib<->Lwt integration.

interrupt [Lwt_read_line.​Control]

accept instance = send_command instance Command.Break

inverse [Lwt_term]
io_vector [Lwt_unix]

Creates an io-vector

io_vector [Lwt_bytes]
is_busy [Lwt_io]

is_busy channel returns whether the given channel is currently busy.

is_empty [Lwt_stream]

is_empty enum returns wether the given stream is empty

is_empty [Lwt_sequence]

Returns true iff the given sequence is empty

is_empty [Lwt_pqueue.​S]
is_empty [Lwt_mutex]

is_empty mutex returns true if they are no thread waiting on the mutex, and false otherwise

is_locked [Lwt_mutex]

locked mutex returns whether mutex is currently locked

is_on [Lwt_switch]

is_on switch returns true if the switch is currently on, and false otherwise.

is_ssl [Lwt_ssl]

Are we using an SSL socket?

isatty [Lwt_unix]

Wrapper for Unix.isatty

iter [Lwt_engine]

iter block performs one iteration of the main loop.

iter [Lwt_glib]

This function is not related to Lwt.

iter [Lwt_util]

iter f l start a thread for each element in l.

iter [Lwt_stream]
iter_l [Lwt_sequence]

iter_l f s applies f on all elements of s starting from the left

iter_node_l [Lwt_sequence]

iter_l f s applies f on all nodes of s starting from the left

iter_node_r [Lwt_sequence]

iter_l f s applies f on all nodes of s starting from the right

iter_p [Lwt_stream]
iter_p [Lwt_list]
iter_r [Lwt_sequence]

iter_l f s applies f on all elements of s starting from the right

iter_s [Lwt_stream]

iter f s iterates over all elements of the stream

iter_s [Lwt_list]
iter_serial [Lwt_util]

Similar to iter but wait for one thread to terminate before starting the next one.

join [Lwt]

join l waits for all threads in l to terminate.

junk [Lwt_stream]

junk st remove the first element of st.

junk_old [Lwt_stream]

junk_old st removes all elements that are ready to be read without yeilding from st.

junk_while [Lwt_stream]
junk_while_s [Lwt_stream]

junk_while f st removes all elements at the beginning of the streams which satisfy f.

keep [Lwt_react.​S]

keep s keeps a reference to s so it will never be garbage collected.

keep [Lwt_react.​E]

keep e keeps a reference to e so it will never be garbage collected.

key_backspace [Lwt_term]

key_backspace = Key_control '?'

key_enter [Lwt_term]

key_enter = Key_control 'j'

key_escape [Lwt_term]

key_escape = Key_control '['

key_tab [Lwt_term]

key_escape = Key_control 'i'

l1_s [Lwt_signal]
l1_s [Lwt_react.​S]
l2_s [Lwt_signal]
l2_s [Lwt_react.​S]
l3_s [Lwt_signal]
l3_s [Lwt_react.​S]
l4_s [Lwt_signal]
l4_s [Lwt_react.​S]
l5_s [Lwt_signal]
l5_s [Lwt_react.​S]
l6_s [Lwt_signal]
l6_s [Lwt_react.​S]
last_draw [Lwt_read_line.​Terminal]

Draw for the last time, i.e.

last_new [Lwt_stream]

next_new st if no element are available on st without sleeping, then it is the same as next st.

lblack [Lwt_term]
lblue [Lwt_term]
lcyan [Lwt_term]
leave_drawing_mode [Lwt_term]

Restore the state of the terminal

leave_iter_hooks [Lwt_main]

Functions that are called after the main iteration.

length [Lwt_io]

Returns the length of the channel in bytes

length [Lwt_bytes]

Returns the length of the given byte array.

length [Lwt_sequence]

Returns the number of elemenets in the given sequence.

level [Lwt_log.​Section]

level section returns the logging level of section.

lgreen [Lwt_term]
limit [Lwt_signal]
limit [Lwt_react.​S]

limit f s limits the rate of s update with f.

limit [Lwt_react.​E]

limit f e limits the rate of e with f.

limit [Lwt_event]
lines [Lwt_term]

Number of lines of the terminal

lines_of_file [Lwt_io]

lines_of_file name returns a stream of all lines of the file with name name.

lines_of_file [Lwt_text]
lines_to_file [Lwt_io]

lines_to_file name lines writes all lines of lines to files

lines_to_file [Lwt_text]
link [Lwt_unix]

Wrapper for Unix.link

listen [Lwt_unix]

Wrapper for Unix.listen

lmagenta [Lwt_term]
load_history [Lwt_read_line]

load_history filename loads history from filename.

location_key [Lwt_log]

The key for storing current location.

lock [Lwt_mutex]

lock mutex lockcs the mutex, that is:

lockf [Lwt_unix]

Wrapper for Unix.lockf

log [Lwt_log]

log ?section ?logger ~level message logs a message.

log_f [Lwt_log]

log_f is the same as log except that it takes a format string

lookup [Lwt_read_line]

lookup word words lookup for completion of word into words.

lookup_min [Lwt_pqueue.​S]
lred [Lwt_term]
lseek [Lwt_unix.​LargeFile]

Wrapper for Unix.LargeFile.lseek

lseek [Lwt_unix]

Wrapper for Unix.lseek

lstat [Lwt_unix.​LargeFile]

Wrapper for Unix.LargeFile.lstat

lstat [Lwt_unix]

Wrapper for Unix.lstat

lwhite [Lwt_term]
lyellow [Lwt_term]

madvise [Lwt_bytes]

madvise buffer pos len advice advise the kernel about how the program is going to use the part of the memory mapped file between pos and pos + len.

magenta [Lwt_term]
main [Lwt_log.​Section]

The main section.

make [Lwt_log.​Section]

make name creates a section with the given name.

make [Lwt_log]

make ~output ~close creates a new logger.

make [Lwt_io]

make ?buffer_size ?close ~mode perform_io is the main function for creating new channels.

make [Lwt_text]

make ?strict ?encoding ch creates a text channel from a byte channel.

make [Lwt_term.​Zone]

Make a new zone where all points are initialized to Lwt_term.​blank

make [Lwt_read_line.​Control]

Creates a new read-line instance with the given parameters.

make_in_channel [Lwt_chan]

make_in_channel read creates an input channel from the read function.

make_notification [Lwt_unix]

new_notifier ?once f registers a new notifier.

make_out_channel [Lwt_chan]

make_out_channel write creates an output channel from the write function.

make_region [Lwt_util]

make_region sz create a region of size sz.

map [Lwt_term.​Draw]

map ~zone ~x ~y f replace the point at coordinates (x, y) by the result of f applied on it.

map [Lwt_util]

map f l apply f to each element in l and collect the results of the threads thus created.

map [Lwt_stream]
map [Lwt]

map f m map the result of a thread.

map_file [Lwt_bytes]

map_file ~fd ?pos ~shared ?size () maps the file descriptor fd to an array of bytes.

map_list [Lwt_stream]
map_list_s [Lwt_stream]

map_list f st applies f on each element of st and flattens the lists returned

map_p [Lwt_react.​E]
map_p [Lwt_event]
map_p [Lwt_list]
map_s [Lwt_signal]
map_s [Lwt_react.​S]
map_s [Lwt_react.​E]
map_s [Lwt_event]
map_s [Lwt_stream]

map f st maps the value returned by st with f

map_s [Lwt_list]
map_serial [Lwt_util]

Similar to map but wait for one thread to terminate before starting the next one.

map_with_waiting_action [Lwt_util]

map_with_waiting_action f wa l apply f to each element in l and collect the results of the threads thus created.

mapped [Lwt_bytes]

mapped buffer returns true iff buffer is a memory mapped file.

merge_s [Lwt_signal]
merge_s [Lwt_react.​S]
merge_s [Lwt_react.​E]
merge_s [Lwt_event]
mincore [Lwt_bytes]

mincore buffer offset states tests whether the given pages are in the system memory (the RAM).

mkdir [Lwt_unix]

Wrapper for Unix.mkdir

mkfifo [Lwt_unix]

Wrapper for Unix.mkfifo

mode [Lwt_io]

mode ch returns the mode of a channel

name [Lwt_log.​Section]

name section returns the name of section.

names [Lwt_read_line.​Command]

names is the list of all commands (except Char ch) with their name.

nchoose [Lwt]

nchoose l returns the value of all that have succcessfully terminated.

nchoose_split [Lwt]

nchoose_split l does the same as Lwt.​nchoose but also retrurns the list of threads that have not yet terminated.

new_key [Lwt]

new_key () creates a new key.

next [Lwt_react.​E]

next e returns the next occurrence of e

next [Lwt_event]
next [Lwt_stream]

next st remove and returns the next element of the stream, of fail with Lwt_stream.​Empty if the stream is empty.

nget [Lwt_stream]

nget n st remove and returns at most the first n elements of st.

njunk [Lwt_stream]

njunk n st removes at most the first n elements of the stream.

notice [Lwt_log]
notice_f [Lwt_log]
notify [Lwt_signal]
notify [Lwt_event]
notify_p [Lwt_signal]
notify_p [Lwt_event]
notify_s [Lwt_signal]
notify_s [Lwt_event]
npeek [Lwt_stream]

npeek n st returns at most the first n elements of st, without removing them.

npick [Lwt]

npick l is the same as Lwt.​nchoose, except that it cancels all sleeping threads when one terminates.

null [Lwt_log]

Logger which drops everything

null [Lwt_io]

Output which drops everything

null [Lwt_text]

of_array [Lwt_stream]

of_array a creates a stream returning all elements of a

of_bytes [Lwt_io]

Create a channel from a byte array.

of_fd [Lwt_io]

of_fd ?buffer_size ?close ~mode fd creates a channel from a file descriptor.

of_key [Lwt_read_line.​Command]

of_key key returns the command to which a key is mapped.

of_list [Lwt_stream]

of_list l creates a stream returning all elements of l

of_stream [Lwt_react.​E]

of_stream stream creates an event which occurs each time a value is available on the stream.

of_stream [Lwt_event]
of_string [Lwt_bytes]

of_string str returns a newly allocated byte array with the same contents as str.

of_string [Lwt_read_line.​Command]

of_string cld tries to convert a command name to a command.

of_string [Lwt_stream]

of_string str creates a stream returning all characters of str

of_unix_fd [Lwt_io]

of_unix_fd ?buffer_size ?close ~mode fd is a short-hand for:

of_unix_file_descr [Lwt_unix]

Creates a lwt file descriptor from a unix one.

on_cancel [Lwt]

on_cancel t f executes f when t is canceled.

on_failure [Lwt]

on_failure t f executes f when t terminates and fails.

on_readable [Lwt_engine]

on_readable fd f calls f each time fd becomes readable.

on_signal [Lwt_unix]

on_signal signum f calls f each time the signal with numnber signum is received by the process.

on_success [Lwt]

on_success t f executes f when t terminates without failing.

on_termination [Lwt]

on_termination t f executes f when t terminates.

on_timer [Lwt_engine]

on_timer delay repeat f calls f one time after delay seconds.

on_writable [Lwt_engine]

on_readable fd f calls f each time fd becomes writable.

open_connection [Lwt_io]

open_connection ?buffer_size ~mode addr open a connection to the given address and returns two channels for using it.

open_connection [Lwt_chan]
open_file [Lwt_io]

open_file ?buffer_size ?flags ?perm ~mode filename open the file with name filename and returns a channel for reading/writing it.

open_file [Lwt_text]
open_in [Lwt_chan]
open_in_gen [Lwt_chan]
open_out [Lwt_chan]
open_out_gen [Lwt_chan]
open_process [Lwt_process]
open_process_full [Lwt_process]
open_process_in [Lwt_process]
open_process_none [Lwt_process]
open_process_out [Lwt_process]
opendir [Lwt_unix]

Wrapper for Unix.opendir

openfile [Lwt_unix]

Wrapper for Unix.openfile.

out_channel_of_descr [Lwt_chan]
out_channel_of_descr [Lwt_ssl]
output [Lwt_io]

output output mode representation

output [Lwt_chan]
output_binary_int [Lwt_chan]
output_char [Lwt_chan]
output_string [Lwt_chan]
output_value [Lwt_chan]

page_size [Lwt_bytes]

Size of pages.

parse [Lwt_stream]

parse st f parses st with f.

parse_key_raw [Lwt_term]

parse_key_raw st recognize escape sequence in a stream of unicode character.

partition_p [Lwt_list]
partition_s [Lwt_list]
pause [Lwt]

pause () is a sleeping thread which is wake up on the next call to Lwt.​wakeup_paused.

paused_count [Lwt]

paused_count () returns the number of thread currently paused.

peek [Lwt_stream]

peek st returns the first element of the stream, if any, without removing it.

pick [Lwt]

pick l is the same as Lwt.​choose, except that it cancels all sleeping threads when one terminates.

pipe [Lwt_unix]

pipe () creates pipe using Unix.pipe and returns two lwt file descriptors created from unix file_descriptor

pipe [Lwt_io]

pipe ?buffer_size () creates a pipe using Lwt_unix.​pipe and makes two channels from the two returned file descriptors

pipe_in [Lwt_unix]

pipe_in () is the same as Lwt_unix.​pipe but maps only the unix file descriptor for reading into a lwt one.

pipe_out [Lwt_unix]

pipe_out () is the inverse of Lwt_unix.​pipe_in.

plain [Lwt_ssl]
pmap [Lwt_process]
pmap_chars [Lwt_process]
pmap_line [Lwt_process]
pmap_lines [Lwt_process]
points [Lwt_term.​Zone]
pool_size [Lwt_unix]

Maximum number of system threads that can be started.

position [Lwt_io]

position ch Returns the current position in the channel.

pread [Lwt_process]
pread_chars [Lwt_process]
pread_line [Lwt_process]
pread_lines [Lwt_process]
print [Lwt_io]
print [Lwt_text]
print_words [Lwt_read_line]

print_words oc columns strs pretty-prints a list of words.

printc [Lwt_term]

printc st prints the given styled text on standard output.

printf [Lwt_io]
printf [Lwt_text]
printl [Lwt_io]
printl [Lwt_text]
printlc [Lwt_term]

printlc st prints st, then reset styles and prints a newline

printlf [Lwt_io]
printlf [Lwt_text]
protected [Lwt]

protected thread creates a new cancelable thread which behave as thread except that cancelling it does not cancel thread.

proxy [Lwt_bytes]

proxy buffer offset length creates a ``proxy''.

put [Lwt_mvar]

put mvar value puts a value into a mailbox variable.

pwrite [Lwt_process]
pwrite_chars [Lwt_process]
pwrite_line [Lwt_process]
pwrite_lines [Lwt_process]

raw_mode [Lwt_term]

Returns wether the terminal is currently in raw mode

read [Lwt_unix]

read fd buf ofs len has the same semantic as Unix.read, but is cooperative

read [Lwt_io]

read ?count ic reads at most len characters from ic.

read [Lwt_bytes]
read [Lwt_text]
read [Lwt_ssl]
read_bytes [Lwt_ssl]
read_char [Lwt_io]

read_char ic reads the next character of ic.

read_char [Lwt_text]
read_char_opt [Lwt_io]

Same as read_byte but does not raises End_of_file on end of input

read_char_opt [Lwt_text]
read_chars [Lwt_io]

read_chars ic returns a stream holding all characters of ic

read_chars [Lwt_text]
read_float32 [Lwt_io.​NumberIO]

Reads an IEEE single precision floating point value

read_float64 [Lwt_io.​NumberIO]

Reads an IEEE double precision floating point value

read_int [Lwt_io.​NumberIO]

Reads a 32-bits integer as an ocaml int

read_int16 [Lwt_io.​NumberIO]
read_int32 [Lwt_io.​NumberIO]
read_int64 [Lwt_io.​NumberIO]
read_into [Lwt_io]

read_into ic buffer offset length reads up to length bytes, stores them in buffer at offset offset, and returns the number of bytes read.

read_into_exactly [Lwt_io]

read_into_exactly ic buffer offset length reads exactly length bytes and stores them in buffer at offset offset.

read_key [Lwt_term]

Get and decode a key from Lwt_term.​standard_input

read_keyword [Lwt_read_line.​Control]
read_keyword [Lwt_read_line]

read_keyword ?history ?case_sensitive ?mode ~prompt ~keywords () reads one word which is a member of words.

read_line [Lwt_io]

read_line ic reads one complete line from ic and returns it without the end of line.

read_line [Lwt_text]
read_line [Lwt_read_line.​Control]
read_line [Lwt_read_line]

readline ?history ?complete ?mode ?prompt () inputs some text from the user.

read_line_opt [Lwt_io]

Same as Lwt_io.​read_line but do not raise End_of_file on end of input.

read_line_opt [Lwt_text]
read_lines [Lwt_io]

read_lines ic returns a stream holding all lines of ic

read_lines [Lwt_text]
read_password [Lwt_read_line.​Control]
read_password [Lwt_read_line]

read_password ?clipboard ?clear ~prompt () inputs a password from the user.

read_value [Lwt_io]

read_value ic reads a marshaled value from ic

read_yes_no [Lwt_read_line.​Control]
read_yes_no [Lwt_read_line]

read_yes_no ?history ?dynamic prompt () is the same as:

readable [Lwt_unix]

Returns whether the given file descriptor is currently readable.

readable_count [Lwt_engine]

Returns the number of events waiting for a file descriptor to become readable.

readdir [Lwt_unix]

Wrapper for Unix.dir

readdir_n [Lwt_unix]

readdir_n handle count reads at most count entry from the given directory.

readlink [Lwt_unix]

Wrapper for Unix.readlink

really_input [Lwt_chan]
recv [Lwt_unix]

Wrapper for Unix.recv

recv [Lwt_bytes]
recv_msg [Lwt_unix]

recv_msg ~socket ~io_vectors receives data into a list of io-vectors, plus any file-descriptors that may accompany the message.

recv_msg [Lwt_bytes]

This call is not available on windows.

recvfrom [Lwt_unix]

Wrapper for Unix.recvfrom

recvfrom [Lwt_bytes]
red [Lwt_term]
register_action [Lwt_unix]

register_action set fd action registers action on fd.

register_pause_notifier [Lwt]

register_pause_notifier f register a function f that will be called each time pause is called.

reinstall_signal_handler [Lwt_unix]

reinstall_signal_handler signum if any signal handler is registered for this signal with Lwt_unix.​on_signal, it reinstall the signal handler (with Sys.set_signal).

remove [Lwt_glib]

Remove the Glib<->Lwt integration.

remove [Lwt_sequence]

Removes a node from the sequence it is part of.

remove_min [Lwt_pqueue.​S]
rename [Lwt_unix]

Wrapper for Unix.rename

render [Lwt_log]

render ~buffer ~template ~section ~level ~message instantiate all variables of template, and store the result in buffer.

render [Lwt_term]

Render an offscreen array to the terminal.

render_state [Lwt_read_line.​Control]

Return the rendering state of the given state

render_update [Lwt_term]

render_update displayed to_display does the same as render to_display but assumes that displayed contains the current displayed text.

reset [Lwt_term]
reset [Lwt_read_line.​Engine]

reset state reset the given state, if the user was doing a selection, it is canceled

reset_level [Lwt_log.​Section]

reset_level section resets the level of section to its default value, i.e.

resize_buffer [Lwt_io]

Resize the internal buffer to the given size

resize_region [Lwt_util]

resize_region reg sz resize the region reg to size sz.

result [Lwt_read_line.​Control]

Threads waiting for the read-line instance to terminates

return [Lwt_signal]
return [Lwt_react.​S]

Same as const.

return [Lwt]

return e is a thread whose return value is the value of the expression e.

rev_map_p [Lwt_list]
rev_map_s [Lwt_list]
rewinddir [Lwt_unix]

Wrapper for Unix.rewinddir

rmdir [Lwt_unix]

Wrapper for Unix.rmdir

rules [Lwt_log_rules]

parse lexbuf returns the list of rules contained in lexbuf

run [Lwt_main]

run t calls the Lwt scheduler repeatedly until t terminates, then returns the value returned by the thread.

run_in_region [Lwt_util]

run_in_region reg size f execute the thread produced by the function f in the region reg.

run_p [Lwt_react.​E]
run_p [Lwt_event]
run_s [Lwt_signal]
run_s [Lwt_react.​S]
run_s [Lwt_react.​E]
run_s [Lwt_event]

sample_s [Lwt_signal]
sample_s [Lwt_react.​S]
save_history [Lwt_read_line]

save_history filename history saves history to filename.

send [Lwt_unix]

Wrapper for Unix.send

send [Lwt_bytes]
send_command [Lwt_read_line.​Control]

send_command instance command sends the given command to the read-line instance

send_msg [Lwt_unix]

send_msg ~socket ~io_vectors ~fds sends data from a list of io-vectors, accompanied with a list of file-descriptor.

send_msg [Lwt_bytes]

This call is not available on windows.

send_notification [Lwt_unix]

send_notification id sends a notification.

sendto [Lwt_unix]

Wrapper for Unix.sendto

sendto [Lwt_bytes]
sequence_mapping [Lwt_term]

Mapping from sequence to keys

set [Lwt_engine]

set ?transfer ?destroy engine replaces the current engine by the given one.

set [Lwt_bytes]

get buffer offset value changes the value of the byte at offset offset in buffer to value.

set [Lwt_term.​Draw]

set ~zone ~x ~y ~popint sets point at relative position x and y.

set [Lwt_sequence]

Change the contents of a node

set_affinity [Lwt_unix]

set_affinity ?pid cpus sets the list of CPUs the given process is allowed to run on.

set_blocking [Lwt_unix]

set_blocking fd b puts fd in blocking or non-blocking mode.

set_bounds [Lwt_preemptive]

set_bounds (min, max) set the minimum and the maximum number of preemptive threads.

set_close_on_exec [Lwt_unix]

Wrapper for Unix.set_close_on_exec

set_color [Lwt_term]

set_color num (red, green, blue) sets the three components of the color number num

set_completion_mode [Lwt_top]

Change the completion mode

set_default_async_method [Lwt_unix]

Sets the default async method.

set_default_buffer_size [Lwt_io]

Change the default buffer size.

set_exn_handler [Lwt_timeout]

set the default handler for exception occurring after a timeout.

set_level [Lwt_log.​Section]

set_level section sets the logging level of the given section.

set_max_number_of_threads_queued [Lwt_preemptive]

Sets the size of the waiting queue, if no more preemptive threads are available.

set_notification [Lwt_unix]

set_notification id f replace the function associated to the notification by f.

set_pool_size [Lwt_unix]

Change the size of the pool.

set_position [Lwt_io]

set_position ch pos Sets the position in the output channel.

setsockopt [Lwt_unix]

Wrapper for Unix.setsockopt

setsockopt_float [Lwt_unix]

Wrapper for Unix.setsockopt_float

setsockopt_int [Lwt_unix]

Wrapper for Unix.setsockopt_int

setsockopt_optint [Lwt_unix]

Wrapper for Unix.setsockopt_optint

shell [Lwt_process]

A command executed with "/bin/sh"

show [Lwt_read_line.​Control]

Un-hide everything

show_cursor [Lwt_term]

show_cursor () makes the cursor visible

shutdown [Lwt_unix]

Wrapper for Unix.shutdown

shutdown [Lwt_ssl]
shutdown_server [Lwt_io]

Shutdown the given server

signal [Lwt_condition]

signal condvar value notifies that a condition is ready.

signal_count [Lwt_unix]

Returns the number of registered signal handler.

simple_init [Lwt_preemptive]

simple_init () does a simple initialization.

size [Lwt_term]

Size of the terminal.

size [Lwt_pqueue.​S]
sleep [Lwt_unix]

sleep d is a threads which remain suspended for d seconds and then terminates.

socket [Lwt_unix]

socket domain type proto is the same as Unix.socket but maps the result into a lwt file descriptor

socketpair [Lwt_unix]

Wrapper for Unix.socketpair

ssl_accept [Lwt_ssl]
ssl_connect [Lwt_ssl]
ssl_shutdown [Lwt_ssl]
standard_input [Lwt_term]

The input stream used by Lwt_term.​read_key

start [Lwt_timeout]

starts a timeout.

stat [Lwt_unix.​LargeFile]

Wrapper for Unix.LargeFile.stat

stat [Lwt_unix]

Wrapper for Unix.stat

state [Lwt_unix]

state fd returns the state of fd

state [Lwt]

state t returns the state of a thread

stderr [Lwt_unix]

The standard file descriptor for printing error messages

stderr [Lwt_io]

The standard output for error messages, it writes data to Lwt_unix.​stderr

stderr [Lwt_text]
stdin [Lwt_unix]

The standard file descriptor for input.

stdin [Lwt_io]

The standard input, it reads data from Lwt_unix.​stdin

stdin [Lwt_text]
stdout [Lwt_unix]

The standard file descriptor for output

stdout [Lwt_io]

The standard output, it writes data to Lwt_unix.​stdout

stdout [Lwt_text]
stop [Lwt_timeout]

stops a timeout.

stop_event [Lwt_engine]

stop_event event stops the given event.

stop_notification [Lwt_unix]

Stop the given notification.

string_of_key [Lwt_term]

string_of_key key string representation of a key

strip_styles [Lwt_term]

Drop all styles

styled_length [Lwt_term]

Returns the length (in unicode character) of the given styled text.

sub [Lwt_term.​Zone]

sub ~zone ~x ~y ~width ~height creates a sub-zone of zone.

symlink [Lwt_unix]

Wrapper for Unix.symlink

syslog [Lwt_log]

syslog ?template ?paths ~facility () creates an logger which send message to the system logger.

system [Lwt_unix]

Wrapper for Unix.system

system_byte_order [Lwt_io]

take [Lwt_mvar]

take mvar will take any currently available value from the mailbox variable.

take_l [Lwt_sequence]

take_l x s remove and returns the leftmost element of s

take_opt_l [Lwt_sequence]

take_opt_l x s remove and returns Some x where x is the leftmost element of s or None if s is empty

take_opt_r [Lwt_sequence]

take_opt_l x s remove and returns Some x where x is the rightmost element of s or None if s is empty

take_r [Lwt_sequence]

take_l x s remove and returns the rightmost element of s

task [Lwt]

task () is the same as wait () except that threads created with task can be canceled.

tcdrain [Lwt_unix]

Wrapper for Unix.tcdrain

tcflow [Lwt_unix]

Wrapper for Unix.tcflow

tcflush [Lwt_unix]

Wrapper for Unix.tcflush

tcgetattr [Lwt_unix]

Wrapper for Unix.tcgetattr

tcsendbreak [Lwt_unix]

Wrapper for Unix.tcsendbreak

tcsetattr [Lwt_unix]

Wrapper for Unix.tcsetattr

text [Lwt_term.​Draw]

Draw the given text at the given positon

text [Lwt_term]
textc [Lwt_term.​Draw]

Same as Lwt_term.​Draw.​text but takes a text with styles

textf [Lwt_term.​Draw]

Same as Lwt_term.​Draw.​text but uses a format string

textf [Lwt_term]

textf fmt formats a texts with fmt and returns Text txt

thread_count [Lwt_unix]

The number of system threads running (excluding this one).

thread_waiting_count [Lwt_unix]

The number threads waiting for a job.

timeout [Lwt_unix]

timeout d is a threads which remain suspended for d seconds then fail with Lwt_unix.​Timeout

timer_count [Lwt_engine]

Returns the number of registered timers.

to_list [Lwt_stream]

Returns the list of elements of the given stream

to_stream [Lwt_react.​E]

Creates a stream holding all values occurring on the given event

to_stream [Lwt_event]
to_string [Lwt_bytes]

to_string buf returns a newly allocated string with the same contents as buf.

to_string [Lwt_read_line.​Command]

to_string cmd returns a string representation of a command

to_string [Lwt_stream]

Returns the word composed of all characters of the given stream

transfer_l [Lwt_sequence]

transfer_l s1 s2 removes all elements of s1 and add them at the left of s2.

transfer_r [Lwt_sequence]

transfer_r s1 s2 removes all elements of s1 and add them at the right of s2.

truncate [Lwt_unix.​LargeFile]

Wrapper for Unix.LargeFile.truncate

truncate [Lwt_unix]

Wrapper for Unix.truncate

try_bind [Lwt]

try_bind t f g behaves as bind (t ()) f if t does not fail.

turn_off [Lwt_switch]

turn_off switch turns off the switch.

underlined [Lwt_term]
union [Lwt_pqueue.​S]
unix_file_descr [Lwt_unix]

Returns the underlying unix file descriptor.

unlink [Lwt_unix]

Wrapper for Unix.unlink

unlock [Lwt_mutex]

unlock mutex unlock the mutex if no threads is waiting on it.

unsafe_blit [Lwt_bytes]

Same as Lwt_bytes.​blit but without bound checking.

unsafe_blit_bytes_string [Lwt_bytes]

Same as Lwt_bytes.​blit_bytes_string but without bound checking.

unsafe_blit_string_bytes [Lwt_bytes]

Same as Lwt_bytes.​blit_string_bytes but without bound checking.

unsafe_fill [Lwt_bytes]

Same as Lwt_bytes.​fill but without bound checking.

unsafe_get [Lwt_bytes]

Same as Lwt_bytes.​get but without bound checking.

unsafe_set [Lwt_bytes]

Same as Lwt_bytes.​set but without bound checking.

update [Lwt_read_line.​Engine]

update ~state ?clipboard ~command () update an engine state by processing the given command.

use [Lwt_pool]

use p f takes one free member of the pool p and gives it to the function f.

wait [Lwt_unix]

Wrapper for Unix.wait

wait [Lwt_throttle.​S]
wait [Lwt]

wait () is a pair of a thread which sleeps forever (unless it is resumed by one of the functions wakeup, wakeup_exn below) and the corresponding wakener.

wait [Lwt_condition]

wait mutex condvar will cause the current thread to block, awaiting notification for a condition variable, condvar.

wait4 [Lwt_unix]

wait4 flags pid returns (pid, status, rusage) where (pid, status) is the same result as Unix.waitpid flags pid, and rusage contains accounting information about the child.

wait_count [Lwt_unix]

Returns the number of threads waiting for a child to terminate.

wait_for_jobs [Lwt_unix]

Wait for all pending jobs to terminate.

wait_mincore [Lwt_bytes]

wait_mincore buffer offset waits until the page containing the byte at offset offset in the the RAM.

wait_read [Lwt_unix]

waits (without blocking other threads) until there is something to read on the file descriptor

wait_read [Lwt_ssl]
wait_write [Lwt_unix]

waits (without blocking other threads) until it is possible to write on the file descriptor

wait_write [Lwt_ssl]
waiter_of_wakener [Lwt]

Returns the thread associated to a wakener.

waitpid [Lwt_unix]

Wrapper for Unix.waitpid

wakeup [Lwt_glib]

If one thread is blocking on Lwt_glib.​iter, then wakeup () make Lwt_glib.​iter to return immediatly.

wakeup [Lwt]

wakeup t e makes the sleeping thread t terminate and return the value of the expression e.

wakeup_exn [Lwt]

wakeup_exn t e makes the sleeping thread t fail with the exception e.

wakeup_later [Lwt]

Same as Lwt.​wakeup but it is not guaranteed that the thread will be wakeup immediately.

wakeup_later_exn [Lwt]

Same as Lwt.​wakeup_exn but it is not guaranteed that the thread will be wakeup immediately.

wakeup_paused [Lwt]

wakeup_paused () wakes up all threads which suspended themselves with Lwt.​pause.

warning [Lwt_log]
warning_f [Lwt_log]
white [Lwt_term]
width [Lwt_term.​Zone]
windows [Lwt_sys]

true iff running on windows.

with_async_detach [Lwt_unix]

with_async_none f is a shorthand for:

with_async_none [Lwt_unix]

with_async_none f is a shorthand for:

with_async_switch [Lwt_unix]

with_async_none f is a shorthand for:

with_connection [Lwt_io]

with_connection ?buffer_size ~mode addr f open a connection to the given address and passes the channels to f

with_file [Lwt_io]

with_file ?buffer_size ?flags ?perm ~mode filename f open a file and passes the channel to f.

with_file [Lwt_text]
with_finaliser [Lwt_signal]
with_finaliser [Lwt_react.​S]

with_finaliser f s returns a signal s' which behave as s, except that f is called when s' is garbage collected.

with_finaliser [Lwt_react.​E]

with_finaliser f e returns an event e' which behave as e, except that f is called when e' is garbage collected.

with_finaliser [Lwt_event]
with_lock [Lwt_mutex]

with_lock lock f is used to lock a mutex within a block scope.

with_process [Lwt_process]
with_process_full [Lwt_process]
with_process_in [Lwt_process]
with_process_none [Lwt_process]
with_process_out [Lwt_process]
with_raw_mode [Lwt_term]

with_raw_mode f executes f while the terminal is in ``raw mode''.

with_timeout [Lwt_unix]

with_timeout d f is a short-hand for:

with_value [Lwt]

with_value key value f executes f with value associated to key.

wrap [Lwt]

wrap f calls f and transform the result into a monad.

wrap1 [Lwt]

wrap1 f x applies f on x and returns the result as a thread.

wrap2 [Lwt]
wrap3 [Lwt]
wrap4 [Lwt]
wrap5 [Lwt]
wrap6 [Lwt]
wrap7 [Lwt]
wrap_syscall [Lwt_unix]

wrap_syscall set fd action wrap an action on a file descriptor.

writable [Lwt_unix]

Returns whether the given file descriptor is currently writable.

writable_count [Lwt_engine]

Returns the number of events waiting for a file descriptor to become writable.

write [Lwt_unix]

read fd buf ofs len has the same semantic as Unix.write, but is cooperative

write [Lwt_io]

write oc str writes all characters of str on oc

write [Lwt_bytes]
write [Lwt_text]
write [Lwt_ssl]
write_bytes [Lwt_ssl]
write_char [Lwt_io]

write_char oc char writes char on oc

write_char [Lwt_text]
write_chars [Lwt_io]

write_chars oc chars writes all characters of chars on oc

write_chars [Lwt_text]
write_float32 [Lwt_io.​NumberIO]

Writes an IEEE single precision floating point value

write_float64 [Lwt_io.​NumberIO]

Writes an IEEE double precision floating point value

write_from [Lwt_io]

write_from oc buffer offset length writes up to length bytes to oc, from buffer at offset offset and returns the number of bytes actually written

write_from_exactly [Lwt_io]

write_from_exactly oc buffer offset length writes all length bytes from buffer at offset offset to oc

write_int [Lwt_io.​NumberIO]

Writes an ocaml int as a 32-bits integer

write_int16 [Lwt_io.​NumberIO]
write_int32 [Lwt_io.​NumberIO]
write_int64 [Lwt_io.​NumberIO]
write_line [Lwt_io]

write_line oc str writes str on oc followed by a new-line.

write_line [Lwt_text]
write_lines [Lwt_io]

write_lines oc lines writes all lines of lines to oc

write_lines [Lwt_text]
write_styled [Lwt_term]

write_styled oc st writes st on oc using escape sequences.

write_value [Lwt_io]

write_value oc ?flags x marshals the value x to oc

x [Lwt_term.​Zone]

y [Lwt_term.​Zone]
yellow [Lwt_term]
yield [Lwt_unix]

yield () is a threads which suspends itself and then resumes as soon as possible and terminates.

yield [Lwt_main]

yield () is a threads which suspends itself and then resumes as soon as possible and terminates.

zero [Lwt_io]

Inputs which returns always '\x00'

zero [Lwt_text]