<p>N A has uploaded this change for <strong>review</strong>.</p><p><a href="https://gerrit.asterisk.org/c/asterisk/+/17844">View Change</a></p><pre style="font-family: monospace,monospace; white-space: pre-wrap;">documentation: Document built-in system and channel vars<br><br>Documentation for built-in special system and channel<br>vars is currently outdated, and updating is a manual<br>process since there is no XML documentation for these<br>anywhere.<br><br>This adds documentation for system vars to func_env<br>and for channel vars to func_channel so that they<br>appear along with the corresponding fields that would<br>be accessed using a function.<br><br>ASTERISK-29848 #close<br><br>Change-Id: I6997f925c4a45fffe71321861f5898a8b7182fa9<br>---<br>M funcs/func_channel.c<br>M funcs/func_env.c<br>2 files changed, 84 insertions(+), 0 deletions(-)<br><br></pre><pre style="font-family: monospace,monospace; white-space: pre-wrap;">git pull ssh://gerrit.asterisk.org:29418/asterisk refs/changes/44/17844/1</pre><pre style="font-family: monospace,monospace; white-space: pre-wrap;"><span>diff --git a/funcs/func_channel.c b/funcs/func_channel.c</span><br><span>index 312806d..c6e5ec1 100644</span><br><span>--- a/funcs/func_channel.c</span><br><span>+++ b/funcs/func_channel.c</span><br><span>@@ -278,6 +278,41 @@</span><br><span> same => n,Log(NOTICE, This channel is: ${CHANNEL(state)})</span><br><span> </example></span><br><span> <xi:include xpointer="xpointer(/docs/info[@name='CHANNEL_EXAMPLES'])" /></span><br><span style="color: hsl(120, 100%, 40%);">+ <para>The following channel variables are available as special built-in</span><br><span style="color: hsl(120, 100%, 40%);">+ dialplan channel variables. These variables cannot be set or modified</span><br><span style="color: hsl(120, 100%, 40%);">+ and are read-only.</para></span><br><span style="color: hsl(120, 100%, 40%);">+ <variablelist></span><br><span style="color: hsl(120, 100%, 40%);">+ <variable name="CALLINGPRES"></span><br><span style="color: hsl(120, 100%, 40%);">+ <para>Caller ID presentation for incoming calls (PRI channels)</para></span><br><span style="color: hsl(120, 100%, 40%);">+ </variable></span><br><span style="color: hsl(120, 100%, 40%);">+ <variable name="CALLINGANI2"></span><br><span style="color: hsl(120, 100%, 40%);">+ <para>Caller ANI2 (PRI channels)</para></span><br><span style="color: hsl(120, 100%, 40%);">+ </variable></span><br><span style="color: hsl(120, 100%, 40%);">+ <variable name="CALLINGTON"></span><br><span style="color: hsl(120, 100%, 40%);">+ <para>Caller Type of Number (PRI channels)</para></span><br><span style="color: hsl(120, 100%, 40%);">+ </variable></span><br><span style="color: hsl(120, 100%, 40%);">+ <variable name="CALLINGTNS"></span><br><span style="color: hsl(120, 100%, 40%);">+ <para>Transit Network Selector (PRI channels)</para></span><br><span style="color: hsl(120, 100%, 40%);">+ </variable></span><br><span style="color: hsl(120, 100%, 40%);">+ <variable name="EXTEN"></span><br><span style="color: hsl(120, 100%, 40%);">+ <para>Current extension</para></span><br><span style="color: hsl(120, 100%, 40%);">+ </variable></span><br><span style="color: hsl(120, 100%, 40%);">+ <variable name="CONTEXT"></span><br><span style="color: hsl(120, 100%, 40%);">+ <para>Current context</para></span><br><span style="color: hsl(120, 100%, 40%);">+ </variable></span><br><span style="color: hsl(120, 100%, 40%);">+ <variable name="PRIORITY"></span><br><span style="color: hsl(120, 100%, 40%);">+ <para>Current priority</para></span><br><span style="color: hsl(120, 100%, 40%);">+ </variable></span><br><span style="color: hsl(120, 100%, 40%);">+ <variable name="CHANNEL"></span><br><span style="color: hsl(120, 100%, 40%);">+ <para>Current channel name</para></span><br><span style="color: hsl(120, 100%, 40%);">+ </variable></span><br><span style="color: hsl(120, 100%, 40%);">+ <variable name="UNIQUEID"></span><br><span style="color: hsl(120, 100%, 40%);">+ <para>Current call unique identifier</para></span><br><span style="color: hsl(120, 100%, 40%);">+ </variable></span><br><span style="color: hsl(120, 100%, 40%);">+ <variable name="HANGUPCAUSE"></span><br><span style="color: hsl(120, 100%, 40%);">+ <para>Asterisk cause of hangup (inbound/outbound)</para></span><br><span style="color: hsl(120, 100%, 40%);">+ </variable></span><br><span style="color: hsl(120, 100%, 40%);">+ </variablelist></span><br><span> </description></span><br><span> </function></span><br><span> ***/</span><br><span>diff --git a/funcs/func_env.c b/funcs/func_env.c</span><br><span>index e5e3e70..f5ff3e0 100644</span><br><span>--- a/funcs/func_env.c</span><br><span>+++ b/funcs/func_env.c</span><br><span>@@ -49,6 +49,55 @@</span><br><span> </syntax></span><br><span> <description></span><br><span> <para>Variables starting with <literal>AST_</literal> are reserved to the system and may not be set.</para></span><br><span style="color: hsl(120, 100%, 40%);">+ <para>Additionally, the following system variables are available as special built-in dialplan variables.</span><br><span style="color: hsl(120, 100%, 40%);">+ These variables cannot be set or modified and are read-only.</para></span><br><span style="color: hsl(120, 100%, 40%);">+ <variablelist></span><br><span style="color: hsl(120, 100%, 40%);">+ <variable name="EPOCH"></span><br><span style="color: hsl(120, 100%, 40%);">+ <para>Current unix style epoch</para></span><br><span style="color: hsl(120, 100%, 40%);">+ </variable></span><br><span style="color: hsl(120, 100%, 40%);">+ <variable name="SYSTEMNAME"></span><br><span style="color: hsl(120, 100%, 40%);">+ <para>value of the <literal>systemname</literal> option from <literal>asterisk.conf</literal></para></span><br><span style="color: hsl(120, 100%, 40%);">+ </variable></span><br><span style="color: hsl(120, 100%, 40%);">+ <variable name="ASTCACHEDIR"></span><br><span style="color: hsl(120, 100%, 40%);">+ <para>value of the <literal>astcachedir</literal> option from <literal>asterisk.conf</literal></para></span><br><span style="color: hsl(120, 100%, 40%);">+ </variable></span><br><span style="color: hsl(120, 100%, 40%);">+ <variable name="ASTETCDIR"></span><br><span style="color: hsl(120, 100%, 40%);">+ <para>value of the <literal>astetcdir</literal> option from <literal>asterisk.conf</literal></para></span><br><span style="color: hsl(120, 100%, 40%);">+ </variable></span><br><span style="color: hsl(120, 100%, 40%);">+ <variable name="ASTMODDIR"></span><br><span style="color: hsl(120, 100%, 40%);">+ <para>value of the <literal>astmoddir</literal> option from <literal>asterisk.conf</literal></para></span><br><span style="color: hsl(120, 100%, 40%);">+ </variable></span><br><span style="color: hsl(120, 100%, 40%);">+ <variable name="ASTVARLIBDIR"></span><br><span style="color: hsl(120, 100%, 40%);">+ <para>value of the <literal>astvarlib</literal> option from <literal>asterisk.conf</literal></para></span><br><span style="color: hsl(120, 100%, 40%);">+ </variable></span><br><span style="color: hsl(120, 100%, 40%);">+ <variable name="ASTDBDIR"></span><br><span style="color: hsl(120, 100%, 40%);">+ <para>value of the <literal>astdbdir</literal> option from <literal>asterisk.conf</literal></para></span><br><span style="color: hsl(120, 100%, 40%);">+ </variable></span><br><span style="color: hsl(120, 100%, 40%);">+ <variable name="ASTKEYDIR"></span><br><span style="color: hsl(120, 100%, 40%);">+ <para>value of the <literal>astkeydir</literal> option from <literal>asterisk.conf</literal></para></span><br><span style="color: hsl(120, 100%, 40%);">+ </variable></span><br><span style="color: hsl(120, 100%, 40%);">+ <variable name="ASTDATADIR"></span><br><span style="color: hsl(120, 100%, 40%);">+ <para>value of the <literal>astdatadir</literal> option from <literal>asterisk.conf</literal></para></span><br><span style="color: hsl(120, 100%, 40%);">+ </variable></span><br><span style="color: hsl(120, 100%, 40%);">+ <variable name="ASTAGIDIR"></span><br><span style="color: hsl(120, 100%, 40%);">+ <para>value of the <literal>astagidir</literal> option from <literal>asterisk.conf</literal></para></span><br><span style="color: hsl(120, 100%, 40%);">+ </variable></span><br><span style="color: hsl(120, 100%, 40%);">+ <variable name="ASTSPOOLDIR"></span><br><span style="color: hsl(120, 100%, 40%);">+ <para>value of the <literal>astspooldir</literal> option from <literal>asterisk.conf</literal></para></span><br><span style="color: hsl(120, 100%, 40%);">+ </variable></span><br><span style="color: hsl(120, 100%, 40%);">+ <variable name="ASTRUNDIR"></span><br><span style="color: hsl(120, 100%, 40%);">+ <para>value of the <literal>astrundir</literal> option from <literal>asterisk.conf</literal></para></span><br><span style="color: hsl(120, 100%, 40%);">+ </variable></span><br><span style="color: hsl(120, 100%, 40%);">+ <variable name="ASTLOGDIR"></span><br><span style="color: hsl(120, 100%, 40%);">+ <para>value of the <literal>astlogdir</literal> option from <literal>asterisk.conf</literal></para></span><br><span style="color: hsl(120, 100%, 40%);">+ </variable></span><br><span style="color: hsl(120, 100%, 40%);">+ <variable name="ASTSBINDIR"></span><br><span style="color: hsl(120, 100%, 40%);">+ <para>value of the <literal>astsbindir</literal> option from <literal>asterisk.conf</literal></para></span><br><span style="color: hsl(120, 100%, 40%);">+ </variable></span><br><span style="color: hsl(120, 100%, 40%);">+ <variable name="ENTITYID"></span><br><span style="color: hsl(120, 100%, 40%);">+ <para>Global Entity ID set automatically, or from <literal>asterisk.conf</literal></para></span><br><span style="color: hsl(120, 100%, 40%);">+ </variable></span><br><span style="color: hsl(120, 100%, 40%);">+ </variablelist></span><br><span> </description></span><br><span> </function></span><br><span> <function name="STAT" language="en_US"></span><br><span></span><br></pre><p>To view, visit <a href="https://gerrit.asterisk.org/c/asterisk/+/17844">change 17844</a>. To unsubscribe, or for help writing mail filters, visit <a href="https://gerrit.asterisk.org/settings">settings</a>.</p><div itemscope itemtype="http://schema.org/EmailMessage"><div itemscope itemprop="action" itemtype="http://schema.org/ViewAction"><link itemprop="url" href="https://gerrit.asterisk.org/c/asterisk/+/17844"/><meta itemprop="name" content="View Change"/></div></div>
<div style="display:none"> Gerrit-Project: asterisk </div>
<div style="display:none"> Gerrit-Branch: 19 </div>
<div style="display:none"> Gerrit-Change-Id: I6997f925c4a45fffe71321861f5898a8b7182fa9 </div>
<div style="display:none"> Gerrit-Change-Number: 17844 </div>
<div style="display:none"> Gerrit-PatchSet: 1 </div>
<div style="display:none"> Gerrit-Owner: N A <mail@interlinked.x10host.com> </div>
<div style="display:none"> Gerrit-MessageType: newchange </div>