Adaptive Framework
0.9.0
|
Files | |
file | afw_service.h |
Adaptive Framework service support. | |
Data Structures | |
struct | afw_service_s |
Runtime service struct. More... | |
Typedefs | |
typedef void(* | afw_service_create_cede_p_t) (afw_service_t *service, void *data, const afw_object_t *properties, const afw_pool_t *p, afw_xctx_t *xctx) |
Function passed to afw_service_start_cede_p. | |
Functions | |
void | afw_service_context_prepare (const afw_service_t *service, const afw_pool_t *p, afw_xctx_t *xctx) |
Prepare expression evaluation context for service::. More... | |
const afw_utf8_t * | afw_service_startup_as_utf8 (afw_service_startup_t startup) |
Convert afw_service_startup_t enum to corresponding utf8. More... | |
const afw_value_t * | afw_service_startup_as_value (afw_service_startup_t startup) |
Convert afw_service_startup_t enum to corresponding adaptive value. More... | |
const afw_utf8_t * | afw_service_startup_description (afw_service_startup_t startup) |
Get description for a afw_service_startup_t enum. More... | |
const afw_value_t * | afw_service_startup_description_as_value (afw_service_startup_t startup) |
Get description as value for a afw_service_startup_t enum. More... | |
afw_service_startup_t | afw_service_startup_as_enum (const afw_utf8_t *s) |
Convert utf8 to corresponding afw_service_startup_t enum. More... | |
const afw_utf8_t * | afw_service_status_as_utf8 (afw_service_status_t status) |
Convert afw_service_status_t enum to corresponding utf8. More... | |
const afw_value_t * | afw_service_status_as_value (afw_service_status_t status) |
Convert afw_service_status_t enum to corresponding adaptive value. More... | |
const afw_utf8_t * | afw_service_status_description (afw_service_status_t status) |
Get description for a afw_service_status_t enum. More... | |
const afw_value_t * | afw_service_status_description_as_value (afw_service_status_t status) |
Get description as value for a afw_service_status_t enum. More... | |
afw_service_status_t | afw_service_status_as_enum (const afw_utf8_t *s) |
Convert utf8 to corresponding afw_service_status_t enum. More... | |
const afw_object_t * | afw_service_get_object (const afw_utf8_t *service_id, const afw_pool_t *p, afw_xctx_t *xctx) |
Get a service object. More... | |
void | afw_service_start_using_AdaptiveConf_cede_p (const afw_object_t *properties, const afw_utf8_t *source_location, const afw_pool_t *p, afw_xctx_t *xctx) |
Start a service using AdaptiveConf object and cede p. More... | |
void | afw_service_start (const afw_utf8_t *service_id, afw_boolean_t manual_start, afw_xctx_t *xctx) |
Start a service. More... | |
void | afw_service_stop (const afw_utf8_t *service_id, afw_xctx_t *xctx) |
Stop a service. More... | |
void | afw_service_restart (const afw_utf8_t *service_id, afw_xctx_t *xctx) |
Restart a service. More... | |
Adaptive service API.
void afw_service_context_prepare | ( | const afw_service_t * | service, |
const afw_pool_t * | p, | ||
afw_xctx_t * | xctx | ||
) |
Prepare expression evaluation context for service::.
service | for which the request is being made. |
p | used for result. |
xctx | of caller. |
<em>AdaptiveAuthorizationResult</em> | object. |
Definition at line 20 of file afw_service_context.c.
const afw_object_t* afw_service_get_object | ( | const afw_utf8_t * | service_id, |
const afw_pool_t * | p, | ||
afw_xctx_t * | xctx | ||
) |
void afw_service_restart | ( | const afw_utf8_t * | service_id, |
afw_xctx_t * | xctx | ||
) |
Restart a service.
service_id | to start. |
xctx | of caller. |
Definition at line 1465 of file afw_service.c.
void afw_service_start | ( | const afw_utf8_t * | service_id, |
afw_boolean_t | manual_start, | ||
afw_xctx_t * | xctx | ||
) |
Start a service.
service_id | to start. |
manual_start | true indicates this is a manual start. |
xctx | of caller. |
Start service if it is not already started. Services with startup immediate and permanent can be started. If manual_start is true, startup manual can also be started.
Definition at line 1201 of file afw_service.c.
void afw_service_start_using_AdaptiveConf_cede_p | ( | const afw_object_t * | properties, |
const afw_utf8_t * | source_location, | ||
const afw_pool_t * | p, | ||
afw_xctx_t * | xctx | ||
) |
Start a service using AdaptiveConf object and cede p.
conf | is compiled AdaptiveConf derived object. |
source_location | of where service defined |
p | to cede control to create function. |
xctx | of caller. |
Parameter conf should be a AdaptiveConf object that is in the p pool that has been validated and any compilable values compiled.
Definition at line 1147 of file afw_service.c.
afw_service_startup_t afw_service_startup_as_enum | ( | const afw_utf8_t * | s | ) |
Convert utf8 to corresponding afw_service_startup_t enum.
startup | utf8. |
Definition at line 195 of file afw_service.c.
const afw_utf8_t* afw_service_startup_as_utf8 | ( | afw_service_startup_t | startup | ) |
Convert afw_service_startup_t enum to corresponding utf8.
startup | enum. |
Definition at line 135 of file afw_service.c.
const afw_value_t* afw_service_startup_as_value | ( | afw_service_startup_t | startup | ) |
Convert afw_service_startup_t enum to corresponding adaptive value.
startup | enum. |
Definition at line 150 of file afw_service.c.
const afw_utf8_t* afw_service_startup_description | ( | afw_service_startup_t | startup | ) |
Get description for a afw_service_startup_t enum.
startup | enum. |
Definition at line 165 of file afw_service.c.
const afw_value_t* afw_service_startup_description_as_value | ( | afw_service_startup_t | startup | ) |
Get description as value for a afw_service_startup_t enum.
startup | enum. |
Definition at line 180 of file afw_service.c.
afw_service_status_t afw_service_status_as_enum | ( | const afw_utf8_t * | s | ) |
Convert utf8 to corresponding afw_service_status_t enum.
status | utf8. |
Definition at line 270 of file afw_service.c.
const afw_utf8_t* afw_service_status_as_utf8 | ( | afw_service_status_t | status | ) |
Convert afw_service_status_t enum to corresponding utf8.
status | enum. |
Definition at line 210 of file afw_service.c.
const afw_value_t* afw_service_status_as_value | ( | afw_service_status_t | status | ) |
Convert afw_service_status_t enum to corresponding adaptive value.
status | enum. |
Definition at line 225 of file afw_service.c.
const afw_utf8_t* afw_service_status_description | ( | afw_service_status_t | status | ) |
Get description for a afw_service_status_t enum.
status | enum. |
Definition at line 240 of file afw_service.c.
const afw_value_t* afw_service_status_description_as_value | ( | afw_service_status_t | status | ) |
Get description as value for a afw_service_status_t enum.
status | enum. |
Definition at line 255 of file afw_service.c.
void afw_service_stop | ( | const afw_utf8_t * | service_id, |
afw_xctx_t * | xctx | ||
) |
Stop a service.
service_id | to start. |
xctx | of caller. |
Definition at line 1266 of file afw_service.c.