38 AST_RWLOCK_DEFINE_STATIC(mixmonitor_lock);
41 static int table_loaded = 0;
49 ast_log(LOG_ERROR,
"Tried to set mixmonitor methods, but something else has already provided them.\n");
53 mixmonitor_methods = *method_table;
64 ast_log(LOG_ERROR,
"Tried to clear mixmonitor methods, but none are currently loaded.\n");
68 memset(&mixmonitor_methods, 0,
sizeof(mixmonitor_methods));
78 if (!mixmonitor_methods.start) {
79 ast_log(LOG_ERROR,
"No loaded module currently provides MixMonitor starting functionality.\n");
83 return mixmonitor_methods.start(chan, filename, options);
90 if (!mixmonitor_methods.stop) {
91 ast_log(LOG_ERROR,
"No loaded module currently provides MixMonitor stopping functionality.\n");
95 return mixmonitor_methods.stop(chan, mixmon_id);
Main Channel structure associated with a channel.
int ast_start_mixmonitor(struct ast_channel *chan, const char *filename, const char *options)
Start a mixmonitor on a channel with the given parameters.
Asterisk locking-related definitions:
Asterisk main include file. File version handling, generic pbx functions.
#define SCOPED_WRLOCK(varname, lock)
scoped lock specialization for write locks
#define SCOPED_RDLOCK(varname, lock)
scoped lock specialization for read locks
MixMonitor virtual methods table definition.
General Asterisk PBX channel definitions.
int ast_stop_mixmonitor(struct ast_channel *chan, const char *mixmon_id)
Stop a mixmonitor on a channel with the given parameters.
Support for logging to various files, console and syslog Configuration in file logger.conf.
int ast_clear_mixmonitor_methods(void)
Clear the MixMonitor virtual methods table. Use this to cleanup function pointers provided by a modul...
loadable MixMonitor functionality
int ast_set_mixmonitor_methods(struct ast_mixmonitor_methods *method_table)
Setup MixMonitor virtual methods table. Use this to provide the MixMonitor functionality from a loada...