![]() |
Diffusion C API
5.9.4
|
This file contains functions required to implement a state provider; that is, a control client which provides the content of one or more Diffusion topics. More...
Data Structures | |
struct | svc_state_request_s |
When a request for state is passed to a registered handler, this structure is populated with information regarding the client and topic name for which state is being requested. More... | |
struct | svc_state_response_s |
A handler which provides topic state will populate a structure of this type. More... | |
struct | state_handlers_s |
struct | state_params_s |
Structure supplied to a register_state_provider() call. More... | |
Macros | |
#define | STATE_HANDLERS |
Callbacks which can be registered by a state provider. | |
Typedefs | |
typedef struct svc_state_request_s | SVC_STATE_REQUEST_T |
When a request for state is passed to a registered handler, this structure is populated with information regarding the client and topic name for which state is being requested. | |
typedef struct svc_state_response_s | SVC_STATE_RESPONSE_T |
A handler which provides topic state will populate a structure of this type. | |
typedef int(* | on_topic_control_registration_cb )(SESSION_T *session, const char *topic_path, void *context) |
Callback for on_topic_control_registration(). More... | |
typedef int(* | on_state_provider_cb )(SESSION_T *session, const SVC_STATE_REQUEST_T *request, SVC_STATE_RESPONSE_T *response, void *context) |
Callback for on_state_provider(). More... | |
typedef struct state_params_s | STATE_PARAMS_T |
Structure supplied to a register_state_provider() call. | |
Functions | |
void | register_state_provider (SESSION_T *session, const STATE_PARAMS_T params) |
Register a state provider with Diffusion. More... | |
This file contains functions required to implement a state provider; that is, a control client which provides the content of one or more Diffusion topics.
typedef int(* on_state_provider_cb)(SESSION_T *session, const SVC_STATE_REQUEST_T *request, SVC_STATE_RESPONSE_T *response, void *context) |
Callback for on_state_provider().
session | The current active session. |
request | The incoming state request. |
response | A structure to be populated with the state response. |
context | User-supplied context from the register_state_provider() call. |
typedef int(* on_topic_control_registration_cb)(SESSION_T *session, const char *topic_path, void *context) |
Callback for on_topic_control_registration().
session | The current active session. |
path | The path for which a handler has been registered. |
context | User-supplied context from the register_state_provider() call. |