Module: sip-router
Branch: sr_3.0
Commit: e69239060196f60def7807fba1f18ff9cc789f8a
URL:
http://git.sip-router.org/cgi-bin/gitweb.cgi/sip-router/?a=commit;h=e692390…
Author: Daniel-Constantin Mierla <miconda(a)gmail.com>
Committer: Juha Heinanen <jh(a)tutpro.com>
Date: Thu Jan 7 18:38:52 2010 +0100
kex: documented missing functions
- reported by Santiago Gimeno
(cherry picked from commit e97f68ebe9d909f56577b3abdc305395df9db5ba)
---
modules_k/kex/README | 77 ++++++++++++++++++++++++++++++
modules_k/kex/doc/kex_admin.xml | 100 +++++++++++++++++++++++++++++++++++++++
2 files changed, 177 insertions(+), 0 deletions(-)
diff --git a/modules_k/kex/README b/modules_k/kex/README
index b5e1986..99ab563 100644
--- a/modules_k/kex/README
+++ b/modules_k/kex/README
@@ -33,6 +33,10 @@ Daniel-Constantin Mierla
3.5. isbflagset(flag [, branch])
3.6. resetsflag(flag [, branch])
3.7. km_append_branch([uri])
+ 3.8. setdsturi(uri)
+ 3.9. resetdsturi()
+ 3.10. isdsturiset()
+ 3.11. pv_printf(var, str)
4. Exported MI Functions
@@ -52,6 +56,10 @@ Daniel-Constantin Mierla
1.5. setbflag usage
1.6. resetsflag usage
1.7. km_append_branch usage
+ 1.8. >setdsturi usage
+ 1.9. >resetdsturi usage
+ 1.10. >isdsturiset usage
+ 1.11. >pv_printf usage
Chapter 1. Admin Guide
@@ -72,6 +80,10 @@ Chapter 1. Admin Guide
3.5. isbflagset(flag [, branch])
3.6. resetsflag(flag [, branch])
3.7. km_append_branch([uri])
+ 3.8. setdsturi(uri)
+ 3.9. resetdsturi()
+ 3.10. isdsturiset()
+ 3.11. pv_printf(var, str)
4. Exported MI Functions
@@ -113,6 +125,10 @@ Chapter 1. Admin Guide
3.5. isbflagset(flag [, branch])
3.6. resetsflag(flag [, branch])
3.7. km_append_branch([uri])
+ 3.8. setdsturi(uri)
+ 3.9. resetdsturi()
+ 3.10. isdsturiset()
+ 3.11. pv_printf(var, str)
3.1. setsflag(flag)
@@ -243,6 +259,67 @@ km_append_branch();
km_append_branch("sip:alice@sip-router.org");
...
+3.8. setdsturi(uri)
+
+ Set the destination address URI (outbound proxy address).
+
+ Meaning of the parameters is as follows:
+ * uri - Valid SIP URI representing the address where to send the
+ request. It must be a static string, no variables are evaluated at
+ runtime. If you need to set outbound proxy address via a variable,
+ use assginment to $du.
+
+ This function can be used from ANY_ROUTE.
+
+ Example 1.8. >setdsturi usage
+...
+setdsturi("sip:10.0.0.10");
+...
+
+3.9. resetdsturi()
+
+ Reset the destination address URI (outbound proxy address).
+
+ This function can be used from ANY_ROUTE.
+
+ Example 1.9. >resetdsturi usage
+...
+resetdsturi();
+...
+
+3.10. isdsturiset()
+
+ Check if the destination address URI (outbound proxy address) is set.
+
+ This function can be used from ANY_ROUTE.
+
+ Example 1.10. >isdsturiset usage
+...
+if(isdsturiset())
+{
+ ...
+}
+...
+
+3.11. pv_printf(var, str)
+
+ Evalues the str and sets the resulted value to variable var. For
+ backward compatibility reasons, same function can be executed via
+ 'avp_printf(var, str)'.
+
+ Meaning of the parameters is as follows:
+ * var - name of a writable variable
+ * str - string that may contain variables which will be evaluated at
+ runtime.
+
+ This function can be used from ANY_ROUTE.
+
+ Example 1.11. >pv_printf usage
+...
+pv_printf("$ru", "sip:$rU@$fd");
+pv_printf("$avp(x)", "From: $fU - To: $tU");
+...
+
4. Exported MI Functions
4.1. arg
diff --git a/modules_k/kex/doc/kex_admin.xml b/modules_k/kex/doc/kex_admin.xml
index 7fff6a3..2a82593 100644
--- a/modules_k/kex/doc/kex_admin.xml
+++ b/modules_k/kex/doc/kex_admin.xml
@@ -277,6 +277,106 @@ km_append_branch("sip:alice@sip-router.org");
</programlisting>
</example>
</section>
+ <section>
+ <title><function
moreinfo="none">setdsturi(uri)</function></title>
+ <para>
+ Set the destination address URI (outbound proxy address).
+ </para>
+ <para>Meaning of the parameters is as follows:</para>
+ <itemizedlist>
+ <listitem>
+ <para>
+ <emphasis>uri</emphasis> - Valid SIP URI representing the
+ address where to send the request. It must be a static string,
+ no variables are evaluated at runtime. If you need to set
+ outbound proxy address via a variable, use assginment to $du.
+ </para>
+ </listitem>
+ </itemizedlist>
+ <para>
+ This function can be used from ANY_ROUTE.
+ </para>
+ <example>
+ <title><function>>setdsturi</function> usage</title>
+ <programlisting format="linespecific">
+...
+setdsturi("sip:10.0.0.10");
+...
+</programlisting>
+ </example>
+ </section>
+ <section>
+ <title><function
moreinfo="none">resetdsturi()</function></title>
+ <para>
+ Reset the destination address URI (outbound proxy address).
+ </para>
+ <para>
+ This function can be used from ANY_ROUTE.
+ </para>
+ <example>
+ <title><function>>resetdsturi</function> usage</title>
+ <programlisting format="linespecific">
+...
+resetdsturi();
+...
+</programlisting>
+ </example>
+ </section>
+ <section>
+ <title><function
moreinfo="none">isdsturiset()</function></title>
+ <para>
+ Check if the destination address URI (outbound proxy address)
+ is set.
+ </para>
+ <para>
+ This function can be used from ANY_ROUTE.
+ </para>
+ <example>
+ <title><function>>isdsturiset</function> usage</title>
+ <programlisting format="linespecific">
+...
+if(isdsturiset())
+{
+ ...
+}
+...
+</programlisting>
+ </example>
+ </section>
+ <section>
+ <title><function moreinfo="none">pv_printf(var,
str)</function></title>
+ <para>
+ Evalues the str and sets the resulted value to variable var. For
+ backward compatibility reasons, same function can be executed via
+ 'avp_printf(var, str)'.
+ </para>
+ <para>Meaning of the parameters is as follows:</para>
+ <itemizedlist>
+ <listitem>
+ <para>
+ <emphasis>var</emphasis> - name of a writable variable
+ </para>
+ </listitem>
+ <listitem>
+ <para>
+ <emphasis>str</emphasis> - string that may contain variables
+ which will be evaluated at runtime.
+ </para>
+ </listitem>
+ </itemizedlist>
+ <para>
+ This function can be used from ANY_ROUTE.
+ </para>
+ <example>
+ <title><function>>pv_printf</function> usage</title>
+ <programlisting format="linespecific">
+...
+pv_printf("$ru", "sip:$rU@$fd");
+pv_printf("$avp(x)", "From: $fU - To: $tU");
+...
+</programlisting>
+ </example>
+ </section>
</section>
<section>