diff options
Diffstat (limited to 'apps/app_userevent.c')
-rw-r--r-- | apps/app_userevent.c | 40 |
1 files changed, 25 insertions, 15 deletions
diff --git a/apps/app_userevent.c b/apps/app_userevent.c index 91d067d54..6d6354af6 100644 --- a/apps/app_userevent.c +++ b/apps/app_userevent.c @@ -30,21 +30,31 @@ ASTERISK_FILE_VERSION(__FILE__, "$Revision$") #include "asterisk/manager.h" #include "asterisk/app.h" -static char *app = "UserEvent"; - -static char *synopsis = "Send an arbitrary event to the manager interface"; - -static char *descrip = -" UserEvent(eventname[,body]): Sends an arbitrary event to the manager\n" -"interface, with an optional body representing additional arguments. The\n" -"body may be specified as a | delimeted list of headers. Each additional\n" -"argument will be placed on a new line in the event. The format of the\n" -"event will be:\n" -" Event: UserEvent\n" -" UserEvent: <specified event name>\n" -" [body]\n" -"If no body is specified, only Event and UserEvent headers will be present.\n"; +/*** DOCUMENTATION + <application name="UserEvent" language="en_US"> + <synopsis> + Send an arbitrary event to the manager interface. + </synopsis> + <syntax> + <parameter name="eventname" required="true" /> + <parameter name="body" /> + </syntax> + <description> + <para>Sends an arbitrary event to the manager interface, with an optional + <replaceable>body</replaceable> representing additional arguments. The + <replaceable>body</replaceable> may be specified as + a <literal>|</literal> delimeted list of headers. Each additional + argument will be placed on a new line in the event. The format of the + event will be:</para> + <para> Event: UserEvent</para> + <para> UserEvent: <specified event name></para> + <para> [body]</para> + <para>If no <replaceable>body</replaceable> is specified, only Event and UserEvent headers will be present.</para> + </description> + </application> + ***/ +static char *app = "UserEvent"; static int userevent_exec(struct ast_channel *chan, void *data) { @@ -83,7 +93,7 @@ static int unload_module(void) static int load_module(void) { - return ast_register_application(app, userevent_exec, synopsis, descrip); + return ast_register_application_xml(app, userevent_exec); } AST_MODULE_INFO_STANDARD(ASTERISK_GPL_KEY, "Custom User Event Application"); |