Browse code

modules: readme files regenerated - textopsx ... [skip ci]

Kamailio Dev authored on 07/07/2021 10:46:15
Showing 1 changed files
... ...
@@ -34,6 +34,9 @@ Daniel-Constantin Mierla
34 34
               2.13. include_hf_value(hf, hvalue)
35 35
               2.14. exclude_hf_value(hf, hvalue)
36 36
               2.15. hf_value_exists(hf, hvalue)
37
+              2.16. hf_iterator_start(iname)
38
+              2.17. hf_iterator_end(iname)
39
+              2.18. textopsx.f.hf_iterator_next(iname)
37 40
 
38 41
         3. Selects
39 42
 
... ...
@@ -58,7 +61,10 @@ Daniel-Constantin Mierla
58 61
    1.13. include_hf_value usage
59 62
    1.14. exclude_hf_value usage
60 63
    1.15. hf_value_exists usage
61
-   1.16. @hf_value select usage
64
+   1.16. hf_iterator_start usage
65
+   1.17. hf_iterator_end usage
66
+   1.18. hf_iterator_next usage
67
+   1.19. @hf_value select usage
62 68
 
63 69
 Chapter 1. Admin Guide
64 70
 
... ...
@@ -82,6 +88,9 @@ Chapter 1. Admin Guide
82 88
         2.13. include_hf_value(hf, hvalue)
83 89
         2.14. exclude_hf_value(hf, hvalue)
84 90
         2.15. hf_value_exists(hf, hvalue)
91
+        2.16. hf_iterator_start(iname)
92
+        2.17. hf_iterator_end(iname)
93
+        2.18. textopsx.f.hf_iterator_next(iname)
85 94
 
86 95
    3. Selects
87 96
 
... ...
@@ -116,6 +125,9 @@ Chapter 1. Admin Guide
116 125
    2.13. include_hf_value(hf, hvalue)
117 126
    2.14. exclude_hf_value(hf, hvalue)
118 127
    2.15. hf_value_exists(hf, hvalue)
128
+   2.16. hf_iterator_start(iname)
129
+   2.17. hf_iterator_end(iname)
130
+   2.18. textopsx.f.hf_iterator_next(iname)
119 131
 
120 132
 2.1.  msg_apply_changes()
121 133
 
... ...
@@ -406,6 +418,58 @@ if (@hf_value_exists.supported.path == "1") {
406 418
 }
407 419
 ...
408 420
 
421
+2.16.  hf_iterator_start(iname)
422
+
423
+   Start an iterator for headers in the current SIP message. The parameter
424
+   iname is used to identify the iterator. There can be up to 4 iterators
425
+   at the same time, with different name.
426
+
427
+   The parameter can be a dynamic string with variables.
428
+
429
+   This function can be used from ANY_ROUTE.
430
+
431
+   Example 1.16. hf_iterator_start usage
432
+...
433
+hf_iterator_start("i1");
434
+...
435
+
436
+2.17.  hf_iterator_end(iname)
437
+
438
+   Close the iterator identified by iname parameter. The iname value must
439
+   be the same used for sht_iterator_start().
440
+
441
+   The parameter can be dynamic string with variables.
442
+
443
+   This function can be used from ANY_ROUTE.
444
+
445
+   Example 1.17. hf_iterator_end usage
446
+...
447
+hf_iterator_end("i1");
448
+...
449
+
450
+2.18.  textopsx.f.hf_iterator_next(iname)
451
+
452
+   Move the iterator to the next header. It must be called also after
453
+   sht_iterator_start() to get the first header.
454
+
455
+   The return code is false when there is no other header in the list.
456
+
457
+   The item name and value are accessible via variables: $hfitname(iname)
458
+   and $hfitbody(iname).
459
+
460
+   The parameter can be dynamic string with variables.
461
+
462
+   This function can be used from ANY_ROUTE.
463
+
464
+   Example 1.18. hf_iterator_next usage
465
+...
466
+    hf_iterator_start("i1");
467
+    while(hf_iterator_next("i1")) {
468
+        xlog("hdr[$hfitname(i1)] is: $hfitbody(i1)\n");
469
+    }
470
+    hf_iterator_end("i1");
471
+...
472
+
409 473
 3. Selects
410 474
 
411 475
    3.1. @hf_value
... ...
@@ -441,7 +505,7 @@ if (@hf_value_exists.supported.path == "1") {
441 505
      * IDX - Value index, negative value counts from bottom
442 506
      * PARAM_NAME - name of parameter
443 507
 
444
-   Example 1.16. @hf_value select usage
508
+   Example 1.19. @hf_value select usage
445 509
 ...
446 510
 $a = @hf_value.my_header[1].my_param;
447 511
 xplog("L_ERR", "$sel(@hf_value.via[-1]), $sel(@hf_value.from.tag)\n");