Asterisk - The Open Source Telephony Project
18.5.0
|
Callbacks defined by CC monitors. More...
#include <ccss.h>
Data Fields | |
int(* | cancel_available_timer )(struct ast_cc_monitor *monitor, int *sched_id) |
Cancel the running available timer. More... | |
void(* | destructor )(void *private_data) |
Destroy private data on the monitor. More... | |
int(* | request_cc )(struct ast_cc_monitor *monitor, int *available_timer_id) |
Request CCSS. More... | |
int(* | status_response )(struct ast_cc_monitor *monitor, enum ast_device_state devstate) |
Status response to an ast_cc_monitor_status_request(). More... | |
int(* | suspend )(struct ast_cc_monitor *monitor) |
Suspend monitoring. More... | |
const char * | type |
Type of monitor the callbacks belong to. More... | |
int(* | unsuspend )(struct ast_cc_monitor *monitor) |
Unsuspend monitoring. More... | |
Callbacks defined by CC monitors.
int(* cancel_available_timer) (struct ast_cc_monitor *monitor, int *sched_id) |
Cancel the running available timer.
monitor | CC core monitor control. |
sched_id | Available timer scheduler id to cancel. Will never be NULL for a device monitor. |
In most cases, this function will likely consist of just a call to AST_SCHED_DEL. It might have been possible to do this within the core, but unfortunately the mixture of sched_thread and sched usage in Asterisk prevents such usage.
0 | on success |
-1 | on failure. |
Definition at line 657 of file ccss.h.
Referenced by cancel_available_timer(), cc_interface_tree_destroy(), and cc_monitor_failed().
void(* destructor) (void *private_data) |
Destroy private data on the monitor.
private_data | The private data pointer from the monitor. |
Implementers of this callback are responsible for destroying all heap-allocated data in the monitor's private_data pointer, including the private_data itself.
Definition at line 668 of file ccss.h.
Referenced by call_destructor_with_no_monitor(), and cc_monitor_destroy().
int(* request_cc) (struct ast_cc_monitor *monitor, int *available_timer_id) |
Request CCSS.
monitor | CC core monitor control. |
available_timer_id | The scheduler ID for the available timer. Will never be NULL for a device monitor. |
Perform whatever steps are necessary in order to request CC. In addition, the monitor implementation is responsible for starting the available timer in this callback.
0 | on success |
-1 | on failure. |
Definition at line 599 of file ccss.h.
Referenced by request_cc().
int(* status_response) (struct ast_cc_monitor *monitor, enum ast_device_state devstate) |
Status response to an ast_cc_monitor_status_request().
monitor | CC core monitor control. |
devstate | Current status of a Party A device. |
Alert a monitor as to the status of the agent for which the monitor had previously requested a status request.
0 | on success |
-1 | on failure. |
Definition at line 628 of file ccss.h.
Referenced by cc_status_response().
int(* suspend) (struct ast_cc_monitor *monitor) |
const char* type |
Type of monitor the callbacks belong to.
Definition at line 583 of file ccss.h.
Referenced by action_dahdishowchannels(), find_monitor_callbacks(), and Property::load().
int(* unsuspend) (struct ast_cc_monitor *monitor) |
Unsuspend monitoring.
monitor | CC core monitor control. |
Perform the necessary steps to unsuspend monitoring.
0 | on success |
-1 | on failure. |
Definition at line 640 of file ccss.h.
Referenced by unsuspend().