Get the state of a hinted extension for dialplan control.
More...
Go to the source code of this file.
|
static struct ast_module_info | __mod_info = { .name = AST_MODULE, .flags = AST_MODFLAG_LOAD_ORDER , .description = "Gets an extension's state in the dialplan" , .key = "This paragraph is copyright (c) 2006 by Digium, Inc. \In order for your module to load, it must return this \key via a function called \"key\". Any code which \includes this paragraph must be licensed under the GNU \General Public License version 2 or later (at your \option). In addition to Digium's general reservations \of rights, Digium expressly reserves the right to \allow other parties to license this paragraph under \different terms. Any use of Digium, Inc. trademarks or \logos (including \"Asterisk\" or \"Digium\") without \express written permission of Digium, Inc. is prohibited.\n" , .buildopt_sum = "ac1f6a56484a8820659555499174e588" , .load = load_module, .unload = unload_module, .load_pri = AST_MODPRI_DEFAULT, } |
|
static struct ast_module_info * | ast_module_info = &__mod_info |
|
static struct ast_custom_function | extstate_function |
|
Get the state of a hinted extension for dialplan control.
- Author
- Adam Gundy adam@.nosp@m.star.nosp@m.silk..nosp@m.net
Definition in file func_extstate.c.
static void __reg_module |
( |
void |
| ) |
|
|
static |
static void __unreg_module |
( |
void |
| ) |
|
|
static |
static const char* ast_extstate_str |
( |
int |
state | ) |
|
|
static |
static int extstate_read |
( |
struct ast_channel * |
chan, |
|
|
const char * |
cmd, |
|
|
char * |
data, |
|
|
char * |
buf, |
|
|
size_t |
len |
|
) |
| |
|
static |
Definition at line 100 of file func_extstate.c.
References ast_copy_string(), ast_extension_state(), ast_extstate_str(), ast_log(), ast_strlen_zero(), context, exten, LOG_WARNING, and strsep().
110 context = exten = data;
static char exten[AST_MAX_EXTENSION]
char * strsep(char **str, const char *delims)
static const char * ast_extstate_str(int state)
static force_inline int attribute_pure ast_strlen_zero(const char *s)
static int len(struct ast_channel *chan, const char *cmd, char *data, char *buf, size_t buflen)
void ast_log(int level, const char *file, int line, const char *function, const char *fmt,...)
Used for sending a log message This is the standard logger function. Probably the only way you will i...
void ast_copy_string(char *dst, const char *src, size_t size)
Size-limited null-terminating string copy.
int ast_extension_state(struct ast_channel *c, const char *context, const char *exten)
Uses hint and devicestate callback to get the state of an extension.
static char context[AST_MAX_CONTEXT]
static int load_module |
( |
void |
| ) |
|
|
static |
static int unload_module |
( |
void |
| ) |
|
|
static |
struct ast_module_info __mod_info = { .name = AST_MODULE, .flags = AST_MODFLAG_LOAD_ORDER , .description = "Gets an extension's state in the dialplan" , .key = "This paragraph is copyright (c) 2006 by Digium, Inc. \In order for your module to load, it must return this \key via a function called \"key\". Any code which \includes this paragraph must be licensed under the GNU \General Public License version 2 or later (at your \option). In addition to Digium's general reservations \of rights, Digium expressly reserves the right to \allow other parties to license this paragraph under \different terms. Any use of Digium, Inc. trademarks or \logos (including \"Asterisk\" or \"Digium\") without \express written permission of Digium, Inc. is prohibited.\n" , .buildopt_sum = "ac1f6a56484a8820659555499174e588" , .load = load_module, .unload = unload_module, .load_pri = AST_MODPRI_DEFAULT, } |
|
static |
Initial value:= {
.name = "EXTENSION_STATE",
.read_max = 12,
}
static int extstate_read(struct ast_channel *chan, const char *cmd, char *data, char *buf, size_t len)
Definition at line 126 of file func_extstate.c.