78#ifndef NET_NANOCOAP_FILESERVER_H
79#define NET_NANOCOAP_FILESERVER_H
91#define COAPFILESERVER_DIR_DELETE_ETAG (0x6ce88b56u)
void(* nanocoap_fileserver_event_handler_t)(nanocoap_fileserver_event_t event, nanocoap_fileserver_event_ctx_t *ctx)
GCoAP fileserver event callback type.
ssize_t nanocoap_fileserver_handler(coap_pkt_t *pdu, uint8_t *buf, size_t len, coap_request_ctx_t *ctx)
File server handler.
void nanocoap_fileserver_set_event_cb(nanocoap_fileserver_event_handler_t cb, void *arg)
Register a consumer for GCoAP fileserver events Requires the nanocoap_fileserver_callback module.
nanocoap_fileserver_event_t
GCoAP fileserver event types.
@ NANOCOAP_FILESERVER_GET_FILE_START
file download started
@ NANOCOAP_FILESERVER_PUT_FILE_END
file upload finished
@ NANOCOAP_FILESERVER_DELETE_FILE
file deletion requested (called before file is deleted)
@ NANOCOAP_FILESERVER_GET_FILE_END
file download finished
@ NANOCOAP_FILESERVER_PUT_FILE_START
file upload started
CoAP resource request handler context.
CoAP PDU parsing context structure.
GCoAP fileserver event context.
const char * path
VFS path of the affected file
void * user_ctx
Optional user supplied context.