Skip to content

Commit

Permalink
modules: readme files regenerated - pv ... [skip ci]
Browse files Browse the repository at this point in the history
  • Loading branch information
kamailio-dev committed Apr 20, 2018
1 parent 42c8595 commit af6c808
Showing 1 changed file with 69 additions and 44 deletions.
113 changes: 69 additions & 44 deletions src/modules/pv/README
Expand Up @@ -42,13 +42,14 @@ Daniel-Constantin Mierla
4.4. typeof(pvar, vtype)
4.5. not_empty(pvar)
4.6. xavp_params_explode(sparams, xname)
4.7. sbranch_set_ruri()
4.8. sbranch_append()
4.9. sbranch_reset()
4.10. pv_xavp_print()
4.11. pv_var_to_xavp(varname, xname)
4.12. pv_xavp_to_var(xname)
4.13. pv_evalx(dst, fmt)
4.7. xavp_params_implode(xname, pvname)
4.8. sbranch_set_ruri()
4.9. sbranch_append()
4.10. sbranch_reset()
4.11. pv_xavp_print()
4.12. pv_var_to_xavp(varname, xname)
4.13. pv_xavp_to_var(xname)
4.14. pv_evalx(dst, fmt)

5. RPC Commands

Expand All @@ -66,15 +67,16 @@ Daniel-Constantin Mierla
1.7. typeof() usage
1.8. not_empty() usage
1.9. xavp_params_explode usage
1.10. sbranch_set_ruri() usage
1.11. sbranch_append() usage
1.10. xavp_params_implode usage
1.11. sbranch_set_ruri() usage
1.12. sbranch_append() usage
1.13. pv_xavp_print() usage
1.14. pv_var_to_xavp() usage
1.15. pv_xavp_to_var() usage
1.13. sbranch_append() usage
1.14. pv_xavp_print() usage
1.15. pv_var_to_xavp() usage
1.16. pv_xavp_to_var() usage
1.17. pv.shvSet usage
1.18. pv.shvGet usage
1.17. pv_xavp_to_var() usage
1.18. pv.shvSet usage
1.19. pv.shvGet usage

Chapter 1. Admin Guide

Expand All @@ -100,13 +102,14 @@ Chapter 1. Admin Guide
4.4. typeof(pvar, vtype)
4.5. not_empty(pvar)
4.6. xavp_params_explode(sparams, xname)
4.7. sbranch_set_ruri()
4.8. sbranch_append()
4.9. sbranch_reset()
4.10. pv_xavp_print()
4.11. pv_var_to_xavp(varname, xname)
4.12. pv_xavp_to_var(xname)
4.13. pv_evalx(dst, fmt)
4.7. xavp_params_implode(xname, pvname)
4.8. sbranch_set_ruri()
4.9. sbranch_append()
4.10. sbranch_reset()
4.11. pv_xavp_print()
4.12. pv_var_to_xavp(varname, xname)
4.13. pv_xavp_to_var(xname)
4.14. pv_evalx(dst, fmt)

5. RPC Commands

Expand Down Expand Up @@ -202,13 +205,14 @@ modparam("pv","avp_aliases","email=s:email_addr;tmp=i:100")
4.4. typeof(pvar, vtype)
4.5. not_empty(pvar)
4.6. xavp_params_explode(sparams, xname)
4.7. sbranch_set_ruri()
4.8. sbranch_append()
4.9. sbranch_reset()
4.10. pv_xavp_print()
4.11. pv_var_to_xavp(varname, xname)
4.12. pv_xavp_to_var(xname)
4.13. pv_evalx(dst, fmt)
4.7. xavp_params_implode(xname, pvname)
4.8. sbranch_set_ruri()
4.9. sbranch_append()
4.10. sbranch_reset()
4.11. pv_xavp_print()
4.12. pv_var_to_xavp(varname, xname)
4.13. pv_xavp_to_var(xname)
4.14. pv_evalx(dst, fmt)

4.1. pv_isset(pvar)

Expand Down Expand Up @@ -305,7 +309,28 @@ xavp_params_explode("a=b;c=d;e=d", "x");
# $xavp(x=>e) = "f";
...

4.7. sbranch_set_ruri()
4.7. xavp_params_implode(xname, pvname)

Serialize the subfields in an XAVP to a parameters string format.

The first parameter has to be the name of XAVP (only the string name,
not the in $xavp(name)). The second parameter is the name of output
variable (in full name, like $var(output)).

The value is stored as string type.

Function can be used from ANY ROUTE.

Example 1.10. xavp_params_implode usage
...
$xavp(x=>e) = "f";
$xavp(x[0]=>c) = "d";
$xavp(x[0]=>a) = "b";
xavp_params_implode("x", "$var(out)");
# results in: $var(out) is "a=b;c=d;e=f;"
...

4.8. sbranch_set_ruri()

Use the attributes from static branch ($sbranch(key) variable) to set
request URI and the other fields of the branch associated with request
Expand All @@ -316,7 +341,7 @@ xavp_params_explode("a=b;c=d;e=d", "x");

Function can be used from REQUEST_ROUTE, BRANCH_ROUTE or FAILURE_ROUTE.

Example 1.10. sbranch_set_ruri() usage
Example 1.11. sbranch_set_ruri() usage
...
sbranch_reset();
$sbranch(uri) = "sip:127.0.0.1:5080";
Expand All @@ -326,7 +351,7 @@ $sbranch(send_socket) = "udp:127.0.0.1:5060";
sbranch_set_ruri();
...

4.8. sbranch_append()
4.9. sbranch_append()

Use the attributes from static branch ($sbranch(key) variable) to
append a new branch to destination set. It is an alternative to
Expand All @@ -338,7 +363,7 @@ sbranch_set_ruri();

Function can be used from REQUEST_ROUTE, BRANCH_ROUTE or FAILURE_ROUTE.

Example 1.11. sbranch_append() usage
Example 1.12. sbranch_append() usage
...
sbranch_reset();
$sbranch(uri) = "sip:127.0.0.1:5080";
Expand All @@ -347,29 +372,29 @@ $sbranch(send_socket) = "udp:127.0.0.1:5060";
sbranch_append();
...

4.9. sbranch_reset()
4.10. sbranch_reset()

Reset the content of static branch ($sbranch(key) variable.

Function can be used from REQUEST_ROUTE, BRANCH_ROUTE or FAILURE_ROUTE.

Example 1.12. sbranch_append() usage
Example 1.13. sbranch_append() usage
...
sbranch_reset();
...

4.10. pv_xavp_print()
4.11. pv_xavp_print()

Print all XAVPs to the syslog using INFO log level.

Function can be used from ANY_ROUTE.

Example 1.13. pv_xavp_print() usage
Example 1.14. pv_xavp_print() usage
...
pv_xavp_print();
...

4.11. pv_var_to_xavp(varname, xname)
4.12. pv_var_to_xavp(varname, xname)

Copy the script variable value into an xavp.

Expand All @@ -381,7 +406,7 @@ pv_xavp_print();

Function can be used from ANY_ROUTE.

Example 1.14. pv_var_to_xavp() usage
Example 1.15. pv_var_to_xavp() usage
...
$var("temp") = 3;
$var("foo") = "foo indeed";
Expand All @@ -395,15 +420,15 @@ $xavp("ok[0]=>temp") now is 3
$xavp("ok[0]=>foo") now is "foo indeed"
...

4.12. pv_xavp_to_var(xname)
4.13. pv_xavp_to_var(xname)

Copy xavp values into vars. Reverse of pv_var_to_xavp().

Both parameters can contain variables that are evaluated at runtime.

Function can be used from ANY_ROUTE.

Example 1.15. pv_xavp_to_var() usage
Example 1.16. pv_xavp_to_var() usage
...
$xavp("bar=>temp") = 3;
$xavp("bar[0]=>foo") = "foo indeed";
Expand All @@ -413,7 +438,7 @@ $var("temp") now is 3
$var("foo") now is "foo indeed"
...

4.13. pv_evalx(dst, fmt)
4.14. pv_evalx(dst, fmt)

The fmt string is evaluated twice for exiting variables, the result is
stored in dst variable. The dst must be the name of a writable
Expand All @@ -422,7 +447,7 @@ $var("foo") now is "foo indeed"

Function can be used from ANY_ROUTE.

Example 1.16. pv_xavp_to_var() usage
Example 1.17. pv_xavp_to_var() usage
...
$var(x) = "test";
$var(y) = "$var(x)"
Expand All @@ -447,7 +472,7 @@ pv_evalx("$var(z)", "$var(y) one");
+ “str”: string value
* _value_: value to be set

Example 1.17. pv.shvSet usage
Example 1.18. pv.shvSet usage
...
$ kamcmd pv.shvSet debug int 3
...
Expand All @@ -461,7 +486,7 @@ $ kamcmd pv.shvSet debug int 3

If no name is given, all shared variables are listed.

Example 1.18. pv.shvGet usage
Example 1.19. pv.shvGet usage
...
$ kamcmd pv.shvGet debug
...

0 comments on commit af6c808

Please sign in to comment.