libjapi  0.3.2
Universal JSON API Library
 All Data Structures Files Functions Variables Typedefs Macros Pages
japi_context Struct Reference

JAPI context struct. More...

#include <japi.h>

Collaboration diagram for japi_context:
Collaboration graph

Data Fields

void * userptr
 
uint16_t num_clients
 
uint16_t max_clients
 
pthread_mutex_t lock
 
struct __japi_request * requests
 
struct __japi_pushsrv_context * push_services
 
struct __japi_client * clients
 
bool include_args_in_response
 
bool shutdown
 
bool init
 

Detailed Description

JAPI context struct.

A JAPI context struct stores several internal information.

Field Documentation

struct __japi_client* japi_context::clients

Pointer to the JAPI client context

Referenced by japi_add_client(), japi_init(), japi_remove_all_clients(), japi_remove_client(), and japi_start_server().

bool japi_context::include_args_in_response

Flag to include request args in response

Referenced by japi_include_args_in_response(), japi_init(), and japi_process_message().

bool japi_context::init

Flag to mark finished initialization

Referenced by japi_init(), and japi_register_request().

pthread_mutex_t japi_context::lock

Mutual access lock

Referenced by japi_add_client(), japi_destroy(), japi_init(), and japi_remove_client().

uint16_t japi_context::max_clients

Number of maximal allowed clients

Referenced by japi_init(), japi_set_max_allowed_clients(), and japi_start_server().

uint16_t japi_context::num_clients

Number of connected clients

Referenced by japi_add_client(), japi_init(), japi_remove_client(), and japi_start_server().

struct __japi_pushsrv_context* japi_context::push_services
struct __japi_request* japi_context::requests

Pointer to the JAPI request list

Referenced by japi_cmd_list(), japi_destroy(), japi_init(), and japi_register_request().

bool japi_context::shutdown

Flag to shutdown the JAPI server

Referenced by japi_init(), japi_shutdown(), and japi_start_server().

void* japi_context::userptr

Pointer to user data

Referenced by japi_init(), and japi_pushsrv_register().


The documentation for this struct was generated from the following file: