Go to the source code of this file.
|
static struct ast_module_info | __mod_info = { .name = AST_MODULE, .flags = AST_MODFLAG_LOAD_ORDER , .description = "PJSIP PIDF Sangoma presence supplement" , .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 = AST_BUILDOPT_SUM, .support_level = AST_MODULE_SUPPORT_CORE, .load = load_module, .unload = unload_module, .load_pri = AST_MODPRI_CHANNEL_DEPEND, .requires = "res_pjsip,res_pjsip_pubsub", } |
|
static const struct ast_module_info * | ast_module_info = &__mod_info |
|
static struct ast_sip_pubsub_body_supplement | pidf_supplement |
|
◆ __reg_module()
static void __reg_module |
( |
void |
| ) |
|
|
static |
◆ __unreg_module()
static void __unreg_module |
( |
void |
| ) |
|
|
static |
◆ AST_MODULE_SELF_SYM()
◆ load_module()
static int load_module |
( |
void |
| ) |
|
|
static |
◆ pidf_supplement_body()
static int pidf_supplement_body |
( |
void * |
body, |
|
|
void * |
data |
|
) |
| |
|
static |
Definition at line 39 of file res_pjsip_pidf_digium_body_supplement.c.
40{
43 char sanitized[1024];
44
45
49
50 return 0;
51 }
52
54 state_data->
pool, body,
"tuple"))) {
56 return -1;
57 }
58
60 state_data->
pool,
node,
"id",
"digium-presence");
61
63 state_data->
pool,
node,
"status"))) {
65 return -1;
66 }
67
69 state_data->
pool,
node,
"digium_presence"))) {
71 return -1;
72 }
73
76 pj_strdup2(state_data->
pool, &
node->content, sanitized);
77 }
78
82
86 state_data->
pool,
node,
"subtype", sanitized);
87 }
88
89 return 0;
90}
const char * ast_presence_state2str(enum ast_presence_state state)
Convert presence state to text string for output.
void ast_sip_sanitize_xml(const char *input, char *output, size_t len)
Replace offensive XML characters with XML entities.
pj_xml_node * ast_sip_presence_xml_create_node(pj_pool_t *pool, pj_xml_node *parent, const char *name)
Create XML node.
pj_xml_attr * ast_sip_presence_xml_create_attr(pj_pool_t *pool, pj_xml_node *node, const char *name, const char *value)
Create XML attribute.
static force_inline int attribute_pure ast_strlen_zero(const char *s)
structure used for presence XML bodies
enum ast_presence_state presence_state
References ast_log, ast_presence_state2str(), ast_sip_presence_xml_create_attr(), ast_sip_presence_xml_create_node(), ast_sip_sanitize_xml(), ast_strlen_zero(), LOG_WARNING, ast_sip_exten_state_data::pool, ast_sip_exten_state_data::presence_message, ast_sip_exten_state_data::presence_state, ast_sip_exten_state_data::presence_subtype, and ast_sip_exten_state_data::user_agent.
◆ unload_module()
static int unload_module |
( |
void |
| ) |
|
|
static |
◆ __mod_info
struct ast_module_info __mod_info = { .name = AST_MODULE, .flags = AST_MODFLAG_LOAD_ORDER , .description = "PJSIP PIDF Sangoma presence supplement" , .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 = AST_BUILDOPT_SUM, .support_level = AST_MODULE_SUPPORT_CORE, .load = load_module, .unload = unload_module, .load_pri = AST_MODPRI_CHANNEL_DEPEND, .requires = "res_pjsip,res_pjsip_pubsub", } |
|
static |
◆ ast_module_info
◆ pidf_supplement