Byte arrays
get buffer offset
returns the byte at offset offset
in
buffer
.
get buffer offset value
changes the value of the byte at
offset offset
in buffer
to value
.
of_string str
returns a newly allocated byte array with the
same contents as str
.
to_string buf
returns a newly allocated string with the same
contents as buf
.
Same as blit but the first buffer is a string instead of a byte array.
Same as blit but the second buffer is a string instead of a byte array.
Same as blit_string_bytes but without bound checking.
Same as blit_bytes_string but without bound checking.
fill buffer offset length value
puts value
in all length
bytes of buffer
starting at offset offset
.
The following functions does the same as the functions in [root:Lwt_unix] except that they use byte arrays instead of strings.
This call is not available on windows.
This call is not available on windows.
map_file ~fd ?pos ~shared ?size ()
maps the file descriptor
fd
to an array of bytes.
mapped buffer
returns true
iff buffer
is a memory mapped
file.
Size of pages.
mincore buffer offset states
tests whether the given pages are
in the system memory (the RAM). The offset
argument must be a
multiple of page_size. states
is used to store the result;
each cases is true
if the corresponding page in the RAM and
false
otherwise.
This call is not available on windows.