Teonet library
0.4.7
|
Macros | |
#define | TSSCR_VERSION "0.0.1" |
Functions | |
void | event_cb_client (ksnetEvMgrClass *ke, ksnetEvMgrEvents event, void *data, size_t data_len, void *user_data) |
Clients Teonet Events callback. More... | |
void | event_cb_server (ksnetEvMgrClass *ke, ksnetEvMgrEvents event, void *data, size_t data_len, void *user_data) |
Servers Teonet Events callback. More... | |
void | event_cb (ksnetEvMgrClass *ke, ksnetEvMgrEvents event, void *data, size_t data_len, void *user_data) |
Common Teonet Events callback. More... | |
int | main (int argc, char **argv) |
Main Subscribe example function. More... | |
void event_cb | ( | ksnetEvMgrClass * | ke, |
ksnetEvMgrEvents | event, | ||
void * | data, | ||
size_t | data_len, | ||
void * | user_data | ||
) |
Common Teonet Events callback.
ke | Pointer to ksnetEvMgrClass |
event | Teonet event selected in ksnetEvMgrEvents enum |
data | Events data |
data_len | Data length |
user_data | User data selected in ksnetEvMgrInitPort() function |
References teonet_cfg::app_argv, EV_K_STARTED, event_cb_client(), event_cb_server(), and ksnetEvMgrClass::teo_cfg.
Referenced by main().
void event_cb_client | ( | ksnetEvMgrClass * | ke, |
ksnetEvMgrEvents | event, | ||
void * | data, | ||
size_t | data_len, | ||
void * | user_data | ||
) |
Clients Teonet Events callback.
ke | Pointer to ksnetEvMgrClass |
event | Teonet event selected in ksnetEvMgrEvents enum |
data | Events data |
data_len | Data length |
user_data | User data selected in ksnetEvMgrInitPort() function |
References teonet_cfg::app_argv, CMD_USER, data, ksnCorePacketData::data, EV_K_CONNECTED, EV_K_RECEIVED, EV_K_SUBSCRIBE, EV_K_TIMER, ksnCorePacketData::from, ksnetEvMgrClass::kc, ksnCoreClass::kco, ksnCoreSendCmdto(), ksnCommandClass::ksscr, rd, ksnetEvMgrClass::teo_cfg, and teoSScrSubscribe().
Referenced by event_cb().
void event_cb_server | ( | ksnetEvMgrClass * | ke, |
ksnetEvMgrEvents | event, | ||
void * | data, | ||
size_t | data_len, | ||
void * | user_data | ||
) |
Servers Teonet Events callback.
ke | Pointer to ksnetEvMgrClass |
event | Teonet event selected in ksnetEvMgrEvents enum |
data | Events data |
data_len | Data length |
user_data | User data selected in ksnetEvMgrInitPort() function |
References ksnCorePacketData::cmd, CMD_USER, data, ksnCorePacketData::data, ksnCorePacketData::data_len, EV_K_DISCONNECTED, EV_K_RECEIVED, free(), ksnCorePacketData::from, ksnCorePacketData::from_len, ksnetEvMgrClass::kc, ksnCoreClass::kco, ksnCommandClass::ksscr, malloc(), rd, teoSScrSend(), and teoSScrUnSubscription().
Referenced by event_cb().
int main | ( | int | argc, |
char ** | argv | ||
) |
Main Subscribe example function.
argc | Number of arguments |
argv | Arguments array |
References ksnetEvMgrAppParam::app_argc, ksnetEvMgrAppParam::app_argv, ksnetEvMgrAppParam::app_descr, APP_PARAM, event_cb(), ke, ksnetEvMgrInitPort(), ksnetEvMgrRun(), ksnetEvMgrSetCustomTimer(), READ_CONFIGURATION, READ_OPTIONS, TSSCR_VERSION, and VERSION.