This shows you the differences between two versions of the page.
Both sides previous revision Previous revision Next revision | Previous revision Next revision Both sides next revision | ||
cookbooks:devel:pseudovariables [2021/07/03 11:45] miconda [$via0(attr) - Via[0] Attributes] |
cookbooks:devel:pseudovariables [2021/07/30 12:38] miconda [Send Data Attributes] |
||
---|---|---|---|
Line 1161: | Line 1161: | ||
</ | </ | ||
- | ==== $rpl(key) ==== | + | ===== $rpl(key) |
Attributes of the SIP reply processed at that moment. The variables must be used during SIP reply processing, otherwise it returns $null. | Attributes of the SIP reply processed at that moment. The variables must be used during SIP reply processing, otherwise it returns $null. | ||
Line 1181: | Line 1181: | ||
} | } | ||
</ | </ | ||
+ | |||
+ | ===== $msgbuf(index) ===== | ||
+ | |||
+ | Get or set the character in the message buffer at the position index. | ||
+ | |||
+ | The index has to be a positive integer or a variable holding such value. | ||
+ | |||
+ | Note that the variable returns a clone of the character stored in a static buffer, copy it to another variable if you want to compare with another $msgbuf(index). | ||
+ | |||
+ | The update is done directly and immediately in the message buffer -- use it with care! | ||
+ | |||
+ | Example of usage: | ||
+ | |||
+ | <code c> | ||
+ | if ($msgbuf(20)==" | ||
+ | $msgbuf(20) = " | ||
+ | } | ||
+ | </ | ||
+ | ===== Header Field Iterator ===== | ||
+ | |||
+ | ====== $hfitname(iname) ====== | ||
+ | |||
+ | The header name of the header field iterator. | ||
+ | |||
+ | Example: | ||
+ | |||
+ | <code c> | ||
+ | hf_iterator_start(" | ||
+ | while(hf_iterator_next(" | ||
+ | xlog(" | ||
+ | } | ||
+ | hf_iterator_end(" | ||
+ | </ | ||
+ | |||
+ | ====== $hfitbody(iname) ====== | ||
+ | |||
+ | The header body of the header field iterator. | ||
+ | |||
+ | Example: | ||
+ | |||
+ | <code c> | ||
+ | hf_iterator_start(" | ||
+ | while(hf_iterator_next(" | ||
+ | xlog(" | ||
+ | } | ||
+ | hf_iterator_end(" | ||
+ | </ | ||
+ | |||
+ | ===== Body Line Iterator ===== | ||
+ | |||
+ | ====== $blitval(iname) ====== | ||
+ | |||
+ | The value of the body line iterator. | ||
+ | |||
+ | Example: | ||
+ | |||
+ | <code c> | ||
+ | bl_iterator_start(" | ||
+ | while(bl_iterator_next(" | ||
+ | xlog(" | ||
+ | } | ||
+ | bl_iterator_end(" | ||
+ | </ | ||
+ | |||
===== Send Data Attributes ===== | ===== Send Data Attributes ===== | ||
Line 2521: | Line 2585: | ||
* received - received parameter value (string) | * received - received parameter value (string) | ||
* i - i parameter value (string) | * i - i parameter value (string) | ||
+ | |||
+ | ===== $via1(attr) - Second Via Attributes ===== | ||
+ | |||
+ | $via1(attr) - attributes of second Via header. The attr can be the same as for $via0(attr). | ||
===== $viaZ(attr) - Last Via Attributes ===== | ===== $viaZ(attr) - Last Via Attributes ===== |