Module io

Module io 

Source
Expand description

I/O Operations related syscalls (that takes a resource) such as read, write, truncate, etc

Functionsยง

diriter_next
Gets the next directory entry from a directory iterator,
diriter_open
Opens a directory iterator for the directory with the resource id dir_ri, returns the resource id of the directory iterator
fattrs
Gets the file attributes of the file with the resource id fd
fsize
Gets the size of the file with the resource id fd
read
Reads buf.len() bytes from the file with the resource id fd at offset offset into buf
sync
Syncs the resource with the resource id ri
sysdiriter_next
Gets the next directory entry from a directory iterator,
sysdiriter_open
Opens a directory iterator for the directory with the resource id dir_ri
sysfattrs
Gets the file attributes of the file with the resource id fd and puts them in dest_attrs
sysfsize
Gets the size of the file with the resource id fd and puts it in dest_size
sysread
Reads len bytes from the file with the resource id fd at offset offset into buf
syssync
Syncs the resource with the resource id fd
systruncate
Truncates the file with the resource id fd to len bytes
syswrite
Writes len bytes from buf to the file with the resource id fd at offset offset
truncate
Truncates the file with the resource id fd to len bytes
write
Writes buf.len() bytes from buf to the file with the resource id fd at offset offset and returns the number of bytes written