Embedded TCP/IP stack
4.7.0
|
typedef fnet_size_t(* fnet_http_srv_post_send_t) (fnet_uint8_t *buffer, fnet_size_t buffer_size, fnet_bool_t *eof, fnet_uint32_t *cookie) |
Callback function prototype of the POST-method response function.
buffer | Output buffer where POST response content will be copied to. |
buffer_size | Size of the output buffer . It's defined by the FNET_CFG_HTTP_SRV_REQUEST_SIZE_MAX parameter. |
eof | Condition flag:
|
cookie | This parameter points to the value, which can be used to associate a custom information with a connection instance. If application store context information in the cookie , it will be preserved for future calls for this request. This allows the application to associate some request-specific state. |
buffer
.eof
indicates if the POST-method end condition has occurred.This function creates the POST-method response content.
An application should use the buffer
as output buffer for the dynamic content and set eof
flag to 1
if no data for output are available.
The HTTP server invokes this callback function after call of the fnet_http_srv_post_handle_t and fnet_http_srv_post_receive_t functions and continues to call this function repeatedly till the eof
will be set to 1
or the return result is set to 0
.
Definition at line 132 of file fnet_http_srv_post.h.