summaryrefslogtreecommitdiff
path: root/funcs/func_dialgroup.c
diff options
context:
space:
mode:
authorRussell Bryant <russell@russellbryant.com>2008-11-01 21:10:07 +0000
committerRussell Bryant <russell@russellbryant.com>2008-11-01 21:10:07 +0000
commit5b168ee34babe562be856ec8f1dd14c0abd7c1a5 (patch)
tree9c836ac808552d20be6bd2baa3a3c29f642eda53 /funcs/func_dialgroup.c
parent1fef0f63bbbde9530837995c8790b839f73b74e7 (diff)
Merge changes from team/group/appdocsxml
This commit introduces the first phase of an effort to manage documentation of the interfaces in Asterisk in an XML format. Currently, a new format is available for applications and dialplan functions. A good number of conversions to the new format are also included. For more information, see the following message to asterisk-dev: http://lists.digium.com/pipermail/asterisk-dev/2008-October/034968.html git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@153365 65c4cc65-6c06-0410-ace0-fbb531ad65f3
Diffstat (limited to 'funcs/func_dialgroup.c')
-rw-r--r--funcs/func_dialgroup.c52
1 files changed, 34 insertions, 18 deletions
diff --git a/funcs/func_dialgroup.c b/funcs/func_dialgroup.c
index c3674beb9..4e4f63389 100644
--- a/funcs/func_dialgroup.c
+++ b/funcs/func_dialgroup.c
@@ -39,6 +39,40 @@ ASTERISK_FILE_VERSION(__FILE__, "$Revision$")
#include "asterisk/astobj2.h"
#include "asterisk/astdb.h"
+/*** DOCUMENTATION
+ <function name="DIALGROUP" language="en_US">
+ <synopsis>
+ Manages a group of users for dialing.
+ </synopsis>
+ <syntax>
+ <parameter name="group" required="true" />
+ <parameter name="op">
+ <para>The operation name, possible values are:</para>
+ <para><literal>add</literal> - add a channel name or interface (write-only)</para>
+ <para><literal>del</literal> - remove a channel name or interface (write-only)</para>
+ </parameter>
+ </syntax>
+ <description>
+ <para>Presents an interface meant to be used in concert with the Dial
+ application, by presenting a list of channels which should be dialled when
+ referenced.</para>
+ <para>When DIALGROUP is read from, the argument is interpreted as the particular
+ <replaceable>group</replaceable> for which a dial should be attempted. When DIALGROUP is written to
+ with no arguments, the entire list is replaced with the argument specified.</para>
+ <para>Functionality is similar to a queue, except that when no interfaces are
+ available, execution may continue in the dialplan. This is useful when
+ you want certain people to be the first to answer any calls, with immediate
+ fallback to a queue when the front line people are busy or unavailable, but
+ you still want front line people to log in and out of that group, just like
+ a queue.</para>
+ <para>Example:</para>
+ <para>exten => 1,1,Set(DIALGROUP(mygroup,add)=SIP/10)</para>
+ <para>exten => 1,n,Set(DIALGROUP(mygroup,add)=SIP/20)</para>
+ <para>exten => 1,n,Dial(${DIALGROUP(mygroup)})</para>
+ </description>
+ </function>
+ ***/
+
static struct ao2_container *group_container = NULL;
struct group_entry {
@@ -232,24 +266,6 @@ static int dialgroup_write(struct ast_channel *chan, const char *cmd, char *data
static struct ast_custom_function dialgroup_function = {
.name = "DIALGROUP",
- .synopsis = "Manages a group of users for dialing",
- .syntax = "DIALGROUP(<group>[,op])",
- .desc =
-" DIALGROUP presents an interface meant to be used in concert with the Dial\n"
-"application, by presenting a list of channels which should be dialled when\n"
-"referenced.\n"
-" When DIALGROUP is read from, the argument is interpreted as the particular\n"
-"group for which a dial should be attempted. When DIALGROUP is written to\n"
-"with no arguments, the entire list is replaced with the argument specified.\n"
-"Other operations are as follows:\n"
-" add - add a channel name or interface (write-only)\n"
-" del - remove a channel name or interface (write-only)\n\n"
-"Functionality is similar to a queue, except that when no interfaces are\n"
-"available, execution may continue in the dialplan. This is useful when\n"
-"you want certain people to be the first to answer any calls, with immediate\n"
-"fallback to a queue when the front line people are busy or unavailable, but\n"
-"you still want front line people to log in and out of that group, just like\n"
-"a queue.\n",
.read = dialgroup_read,
.write = dialgroup_write,
};