| Libtrap: Internal development docs
    1.16.1
    | 
|   | 
| Typedefs | |
| typedef int(* | ifc_recv_func_t) (void *p, void *d, uint32_t *s, int t) | 
| typedef int(* | ifc_send_func_t) (void *p, const void *d, uint16_t s, int t) | 
| typedef void(* | ifc_flush_func_t) (void *p) | 
| typedef void(* | ifc_disconn_clients_func_t) (void *p) | 
| typedef void(* | ifc_terminate_func_t) (void *p) | 
| typedef void(* | ifc_destroy_func_t) (void *p) | 
| typedef void(* | ifc_create_dump_func_t) (void *p, uint32_t i, const char *d) | 
| typedef int32_t(* | ifc_get_client_count_func_t) (void *p) | 
| typedef int8_t(* | ifc_get_client_stats_json_func_t) (void *p, json_t *client_stats_arr) | 
| typedef char *(* | ifc_get_id_func_t) (void *priv) | 
| typedef uint8_t(* | ifc_is_conn_func_t) (void *priv) | 
The set of function that must be implemented for communication interface.
| typedef void(* ifc_create_dump_func_t) (void *p, uint32_t i, const char *d) | 
Create dump of interface for debug purposes.
| [in] | p | pointer to IFC's private memory allocated by constructor | 
| [in] | i | index of interface (index into the IFC array in the context trap_ctx_priv_s) | 
| [in] | d | directory path to generate output | 
Definition at line 137 of file trap_ifc.h.
| typedef void(* ifc_destroy_func_t) (void *p) | 
Destructor, called to free allocated memory.
| [in,out] | p | pointer to IFC's private memory allocated by constructor | 
Definition at line 127 of file trap_ifc.h.
| typedef void(* ifc_disconn_clients_func_t) (void *p) | 
Disconnect all connected clients to output IFC.
| [in] | p | pointer to IFC's private memory allocated by constructor | 
Definition at line 113 of file trap_ifc.h.
| typedef void(* ifc_flush_func_t) (void *p) | 
Force flush on interface
| [in] | p | pointer to IFC's private memory allocated by constructor | 
Definition at line 106 of file trap_ifc.h.
| typedef int32_t(* ifc_get_client_count_func_t) (void *p) | 
Get number of connected clients.
| [in] | p | pointer to IFC's private memory allocated by constructor | 
Definition at line 145 of file trap_ifc.h.
| typedef int8_t(* ifc_get_client_stats_json_func_t) (void *p, json_t *client_stats_arr) | 
Get json array with client statistics
| [in] | p | pointer to IFC's private memory allocated by constructor | 
| [out] | client_stats_arr | pointer to JSON array to be filled with client statistics | 
Definition at line 154 of file trap_ifc.h.
| typedef char*(* ifc_get_id_func_t) (void *priv) | 
Get identifier of the interface
| [in] | priv | pointer to IFC's private memory allocated by constructor | 
Definition at line 164 of file trap_ifc.h.
| typedef uint8_t(* ifc_is_conn_func_t) (void *priv) | 
Check whether the input interface is connected
| [in] | priv | pointer to IFC's private memory allocated by constructor | 
Definition at line 172 of file trap_ifc.h.
| typedef int(* ifc_recv_func_t) (void *p, void *d, uint32_t *s, int t) | 
Receive one message via this IFC.
This function is called from trap_read_from_buffer() when there is a need to get new data.
| [in] | p | pointer to IFC's private memory allocated by constructor | 
| [out] | d | pointer to memory where this IFC can write received message | 
| [out] | s | size (in bytes) of received message (must be set by this IFC) | 
| [in] | t | timeout, see TRAP Timeout | 
Definition at line 85 of file trap_ifc.h.
| typedef int(* ifc_send_func_t) (void *p, const void *d, uint16_t s, int t) | 
Send one message via this IFC.
This function is called from trap_store_into_buffer() when there is a need to send new data.
| [in] | p | pointer to IFC's private memory allocated by constructor | 
| [in] | d | pointer to message that will be sent | 
| [in] | s | size (in bytes) of message that will be sent | 
| [in] | t | timeout, see TRAP Timeout | 
Definition at line 99 of file trap_ifc.h.
| typedef void(* ifc_terminate_func_t) (void *p) | 
Terminate IFC - stop sending/receiving.
| [in] | p | pointer to IFC's private memory allocated by constructor | 
Definition at line 120 of file trap_ifc.h.
 1.8.14
 1.8.14