Page
Library
Module
Module type
Parameter
Class
Class type
Source
All.BAval unsafe_all_pread : Unix.file_descr -> int -> ('a, 'b) carray -> intall_pread fd off buf reads up to size of buf bytes from file descriptor fd at offset off (from the start of the file) into the buffer buf. The file offset is not changed.
all_pread repeats the read operation until all characters have been read or an error occurs. Returns less than the number of characters requested on EAGAIN, EWOULDBLOCK or End-of-file but only ever returns 0 on End-of-file. Continues the read operation on EINTR. Raises an Unix.Unix_error exception in all other cases.
val all_pread : Unix.file_descr -> int -> ('a, 'b) carray -> intval unsafe_single_pread : Unix.file_descr -> int -> ('a, 'b) carray -> intsingle_pread fd off buf reads up to size of buf bytes from file descriptor fd at offset off (from the start of the file) into the buffer buf. The file offset is not changed.
single_pread attempts to read only once. Returns the number of characters read or raises an Unix.Unix_error exception. Unlike the string variant of the same name there is no limit on the number of characters read.
val single_pread : Unix.file_descr -> int -> ('a, 'b) carray -> intval unsafe_pread : Unix.file_descr -> int -> ('a, 'b) carray -> intpread fd off buf reads up to size of buf bytes from file descriptor fd at offset off (from the start of the file) into the buffer buf. The file offset is not changed.
pread repeats the read operation until all characters have been read or an error occurs. Raises an Unix.Unix_error exception if 0 characters could be read before an error occurs. Continues the read operation on EINTR. Returns the number of characters written in all other cases.
val pread : Unix.file_descr -> int -> ('a, 'b) carray -> intval unsafe_intr_pread : Unix.file_descr -> int -> ('a, 'b) carray -> intintr_pread fd off buf reads up to size of buf bytes from file descriptor fd at offset off (from the start of the file) into the buffer buf. The file offset is not changed.
intr_pread repeats the read operation until all characters have been read or an error occurs. Raises an Unix.Unix_error exception if 0 characters could be read before an error occurs. Does NOT continue on EINTR. Returns the number of characters written in all other cases.
val intr_pread : Unix.file_descr -> int -> ('a, 'b) carray -> intval unsafe_all_pwrite : Unix.file_descr -> int -> ('a, 'b) carray -> intall_pwrite fd off buf writes up to size of buf bytes from file descriptor fd at offset off (from the start of the file) into the buffer buf. The file offset is not changed.
all_pwrite repeats the write operation until all characters have been written or an error occurs. Returns less than the number of characters requested on EAGAIN, EWOULDBLOCK but never 0. Continues the write operation on EINTR. Raises an Unix.Unix_error exception in all other cases.
val all_pwrite : Unix.file_descr -> int -> ('a, 'b) carray -> intval unsafe_single_pwrite : Unix.file_descr -> int -> ('a, 'b) carray -> intsingle_pwrite fd off buf writes up to size of buf bytes from file descriptor fd at offset off (from the start of the file) into the buffer buf. The file offset is not changed.
single_pwrite attempts to write only once. Returns the number of characters written or raises an Unix.Unix_error exception. Unlike the string variant of the same name there is no limit on the number of characters written.
val single_pwrite : Unix.file_descr -> int -> ('a, 'b) carray -> intval unsafe_pwrite : Unix.file_descr -> int -> ('a, 'b) carray -> intpwrite fd off buf writes up to size of buf bytes from file descriptor fd at offset off (from the start of the file) into the buffer buf. The file offset is not changed.
pwrite repeats the write operation until all characters have been written or an error occurs. Raises an Unix.Unix_error exception if 0 characters could be written before an error occurs. Continues the write operation on EINTR. Returns the number of characters written in all other cases.
val pwrite : Unix.file_descr -> int -> ('a, 'b) carray -> intval unsafe_intr_pwrite : Unix.file_descr -> int -> ('a, 'b) carray -> intintr_pwrite fd off buf writes up to size of buf bytes from file descriptor fd at offset off (from the start of the file) into the buffer buf. The file offset is not changed.
intr_pwrite repeats the write operation until all characters have been written or an error occurs. Raises an Unix.Unix_error exception if 0 characters could be written before an error occurs. Does NOT continue on EINTR. Returns the number of characters written in all other cases.
val intr_pwrite : Unix.file_descr -> int -> ('a, 'b) carray -> intval all_read : Unix.file_descr -> ('a, 'b) carray -> intall_read fd buf reads up to size of buf bytes from file descriptor fd into the buffer buf.
all_read repeats the read operation until all characters have been read or an error occurs. Returns less than the number of characters requested on EAGAIN, EWOULDBLOCK or End-of-file but only ever returns 0 on End-of-file. Continues the read operation on EINTR. Raises an Unix.Unix_error exception in all other cases.
val single_read : Unix.file_descr -> ('a, 'b) carray -> intsingle_read fd buf reads up to size of buf bytes from file descriptor fd into the buffer buf.
single_read attempts to read only once. Returns the number of characters read or raises an Unix.Unix_error exception. Unlike the string variant of the same name there is no limit on the number of characters read.
val read : Unix.file_descr -> ('a, 'b) carray -> intread fd buf reads up to size of buf bytes from file descriptor fd into the buffer buf.
read repeats the read operation until all characters have been read or an error occurs. Raises an Unix.Unix_error exception if 0 characters could be read before an error occurs. Continues the read operation on EINTR. Returns the number of characters written in all other cases.
val intr_read : Unix.file_descr -> ('a, 'b) carray -> intintr_read fd buf reads up to size of buf bytes from file descriptor fd into the buffer buf.
intr_read repeats the read operation until all characters have been read or an error occurs. Raises an Unix.Unix_error exception if 0 characters could be read before an error occurs. Does NOT continue on EINTR. Returns the number of characters written in all other cases.
val all_write : Unix.file_descr -> ('a, 'b) carray -> intall_write fd buf writes up to size of buf bytes from file descriptor fd into the buffer buf.
all_write repeats the write operation until all characters have been written or an error occurs. Returns less than the number of characters requested on EAGAIN, EWOULDBLOCK but never 0. Continues the write operation on EINTR. Raises an Unix.Unix_error exception in all other cases.
val single_write : Unix.file_descr -> ('a, 'b) carray -> intsingle_write fd buf writes up to size of buf bytes from file descriptor fd into the buffer buf.
single_write attempts to write only once. Returns the number of characters written or raises an Unix.Unix_error exception. Unlike the string variant of the same name there is no limit on the number of characters written.
val write : Unix.file_descr -> ('a, 'b) carray -> intwrite fd buf writes up to size of buf bytes from file descriptor fd into the buffer buf.
write repeats the write operation until all characters have been written or an error occurs. Raises an Unix.Unix_error exception if 0 characters could be written before an error occurs. Continues the write operation on EINTR. Returns the number of characters written in all other cases.
val intr_write : Unix.file_descr -> ('a, 'b) carray -> intintr_write fd buf writes up to size of buf bytes from file descriptor fd into the buffer buf.
intr_write repeats the write operation until all characters have been written or an error occurs. Raises an Unix.Unix_error exception if 0 characters could be written before an error occurs. Does NOT continue on EINTR. Returns the number of characters written in all other cases.
module BigEndian : sig ... endmodule LittleEndian : sig ... endmodule HostEndian : sig ... endval unsafe_get_substr : 'a carray8 -> int -> int -> stringunsafe_get_substr buf off len extracts the substring from buffer buf starting at offset off and length len. Bounds checking is not performed. Use with caution and only when the program logic guarantees that the access is within bounds.
val get_substr :
('a, Bigarray.int8_unsigned_elt, Bigarray.c_layout) Bigarray.Array1.t ->
int ->
int ->
stringget_substr buf off len same as unsafe_get_substr but with bounds checking.
val unsafe_set_substr : 'a carray8 -> int -> string -> unitunsafe_set_substr buf off str stores the string in buffer buf starting at offset off. Bounds checking is not performed. Use with caution and only when the program logic guarantees that the access is within bounds.
val set_substr :
('a, Bigarray.int8_unsigned_elt, Bigarray.c_layout) Bigarray.Array1.t ->
int ->
string ->
unitset_substr buf off str same as unsafe_set_substr but with bounds checking.
I/O vector. Used to send multiple data using a single system call
val vmsplice : Unix.file_descr -> 'a iov array -> splice_flag list -> intvmsplice fd iovs flags sends the data described by iovs to the pipe fd