Module posish::io [−][src]
Expand description
I/O operations.
Structs
O_*
constants for use with dup2
.
The error type for posish APIs.
MAP_*
flags for use with mmap
.
struct pollfd
A Vec
of pollfd
.
POLL*
PROT_*
flags for use with mmap
.
Constants
Functions
dup(fd)
—Creates a new OwnedFd
instance that shares the same
underlying file description as fd
.
dup3(fd, new, flags)
—Creates a new OwnedFd
instance that shares the
same underlying file description as the existing OwnedFd
instance,
closing new
and reusing its file descriptor.
ioctl(fd, FIOCLEX)
ioctl(fd, FIONREAD)
.
ioctl(fd, TCGETS)
ioctl(fd, TIOCGWINSZ)
.
Returns a pair of booleans indicating whether the file descriptor is readable and/or writeable, respectively.
isatty(fd)
mmap(fd, len, prot, flags, fd, offset)
munmap(ptr, len)
pipe()
pread(fd, buf, offset)
preadv(fd, bufs, offset)
pwrite(fd, bufs)
pwritev(fd, bufs, offset)
read(fd, buf)
readv(fd, bufs)
STDERR_FILENO
STDIN_FILENO
STDOUT_FILENO
ttyname_r(fd)
write(fd, buf)
writev(fd, bufs)
Type Definitions
A specialized Result
type for posish APIs.
struct termios
, for use with ioctl_tcgets
.
struct winsize