libwebsockets
Lightweight C library for HTML5 websockets
|
Data Fields | |
lws_fop_fd_t(* | LWS_FOP_OPEN )(const struct lws_plat_file_ops *fops, const char *filename, const char *vpath, lws_fop_flags_t *flags) |
int(* | LWS_FOP_CLOSE )(lws_fop_fd_t *fop_fd) |
lws_fileofs_t(* | LWS_FOP_SEEK_CUR )(lws_fop_fd_t fop_fd, lws_fileofs_t offset_from_cur_pos) |
int(* | LWS_FOP_READ )(lws_fop_fd_t fop_fd, lws_filepos_t *amount, uint8_t *buf, lws_filepos_t len) |
int(* | LWS_FOP_WRITE )(lws_fop_fd_t fop_fd, lws_filepos_t *amount, uint8_t *buf, lws_filepos_t len) |
struct lws_fops_index | fi [3] |
const struct lws_plat_file_ops * | next |
struct lws_fops_index lws_plat_file_ops::fi[3] |
vfs path signatures implying use of this fops
int(* lws_plat_file_ops::LWS_FOP_CLOSE) (lws_fop_fd_t *fop_fd) |
close file AND set the pointer to NULL
lws_fop_fd_t(* lws_plat_file_ops::LWS_FOP_OPEN) (const struct lws_plat_file_ops *fops, const char *filename, const char *vpath, lws_fop_flags_t *flags) |
Open file (always binary access if plat supports it) vpath may be NULL, or if the fops understands it, the point at which the filename's virtual part starts. *flags & LWS_FOP_FLAGS_MASK should be set to O_RDONLY or O_RDWR. If the file may be gzip-compressed, LWS_FOP_FLAG_COMPR_ACCEPTABLE_GZIP is set. If it actually is gzip-compressed, then the open handler should OR LWS_FOP_FLAG_COMPR_IS_GZIP on to *flags before returning.
int(* lws_plat_file_ops::LWS_FOP_READ) (lws_fop_fd_t fop_fd, lws_filepos_t *amount, uint8_t *buf, lws_filepos_t len) |
Read from file, on exit *amount is set to amount actually read
lws_fileofs_t(* lws_plat_file_ops::LWS_FOP_SEEK_CUR) (lws_fop_fd_t fop_fd, lws_fileofs_t offset_from_cur_pos) |
seek from current position
int(* lws_plat_file_ops::LWS_FOP_WRITE) (lws_fop_fd_t fop_fd, lws_filepos_t *amount, uint8_t *buf, lws_filepos_t len) |
Write to file, on exit *amount is set to amount actually written
const struct lws_plat_file_ops* lws_plat_file_ops::next |
NULL or next fops in list