Lely core libraries 2.3.4
|
The virtual table of an I/O device handle. More...
#include <handle.h>
Data Fields | |
int | type |
The type of the device (one of IO_TYPE_CAN, IO_TYPE_FILE, IO_TYPE_PIPE, IO_TYPE_SERIAL or IO_TYPE_SOCK). | |
size_t | size |
The size (in bytes) of the handle struct. | |
void(* | fini )(struct io_handle *handle) |
A pointer to the fini method. | |
int(* | flags )(struct io_handle *handle, int flags) |
A pointer to the static flags method. | |
ssize_t(* | read )(struct io_handle *handle, void *buf, size_t nbytes) |
A pointer to the read method. | |
ssize_t(* | write )(struct io_handle *handle, const void *buf, size_t nbytes) |
A pointer to the write method. | |
int(* | flush )(struct io_handle *handle) |
A pointer to the flush method. | |
io_off_t(* | seek )(struct io_handle *handle, io_off_t offset, int whence) |
A pointer to the seek method. | |
ssize_t(* | pread )(struct io_handle *handle, void *buf, size_t nbytes, io_off_t offset) |
A pointer to the pread method. | |
ssize_t(* | pwrite )(struct io_handle *handle, const void *buf, size_t nbytes, io_off_t offset) |
A pointer to the pwrite method. | |
int(* | purge )(struct io_handle *handle, int flags) |
A pointer to the purge method. | |
ssize_t(* | recv )(struct io_handle *handle, void *buf, size_t nbytes, io_addr_t *addr, int flags) |
A pointer to the recv method. | |
ssize_t(* | send )(struct io_handle *handle, const void *buf, size_t nbytes, const io_addr_t *addr, int flags) |
A pointer to the send method. | |
struct io_handle *(* | accept )(struct io_handle *handle, io_addr_t *addr) |
A pointer to the accept method. | |
int(* | connect )(struct io_handle *handle, const io_addr_t *addr) |
A pointer to the connect method. | |
int(* io_handle_vtab::flush) (struct io_handle *handle) |