Browse code

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

Kamailio Dev authored on 21/09/2021 08:31:29
Showing 1 changed files
... ...
@@ -24,25 +24,30 @@ Daniel-Constantin Mierla
24 24
               2.1. Kamailio Modules
25 25
               2.2. External Libraries or Applications
26 26
 
27
-        3. Functions
27
+        3. Parameters
28 28
 
29
-              3.1. pos_append(idx, val)
30
-              3.2. pos_insert(idx, val)
31
-              3.3. pos_rm(idx, len)
32
-              3.4. pos_headers_start()
33
-              3.5. pos_headers_end()
34
-              3.6. pos_body_start()
35
-              3.7. pos_body_end()
29
+              3.1. idx0 (int)
30
+
31
+        4. Functions
32
+
33
+              4.1. pos_append(idx, val)
34
+              4.2. pos_insert(idx, val)
35
+              4.3. pos_rm(idx, len)
36
+              4.4. pos_headers_start()
37
+              4.5. pos_headers_end()
38
+              4.6. pos_body_start()
39
+              4.7. pos_body_end()
36 40
 
37 41
    List of Examples
38 42
 
39
-   1.1. pos_append() usage
40
-   1.2. pos_insert() usage
41
-   1.3. pos_rm() usage
42
-   1.4. pos_headers_start() usage
43
-   1.5. pos_headers_end() usage
44
-   1.6. pos_body_start() usage
45
-   1.7. pos_body_end() usage
43
+   1.1. Set idx0 parameter
44
+   1.2. pos_append() usage
45
+   1.3. pos_insert() usage
46
+   1.4. pos_rm() usage
47
+   1.5. pos_headers_start() usage
48
+   1.6. pos_headers_end() usage
49
+   1.7. pos_body_start() usage
50
+   1.8. pos_body_end() usage
46 51
 
47 52
 Chapter 1. Admin Guide
48 53
 
... ...
@@ -54,15 +59,19 @@ Chapter 1. Admin Guide
54 59
         2.1. Kamailio Modules
55 60
         2.2. External Libraries or Applications
56 61
 
57
-   3. Functions
62
+   3. Parameters
63
+
64
+        3.1. idx0 (int)
58 65
 
59
-        3.1. pos_append(idx, val)
60
-        3.2. pos_insert(idx, val)
61
-        3.3. pos_rm(idx, len)
62
-        3.4. pos_headers_start()
63
-        3.5. pos_headers_end()
64
-        3.6. pos_body_start()
65
-        3.7. pos_body_end()
66
+   4. Functions
67
+
68
+        4.1. pos_append(idx, val)
69
+        4.2. pos_insert(idx, val)
70
+        4.3. pos_rm(idx, len)
71
+        4.4. pos_headers_start()
72
+        4.5. pos_headers_end()
73
+        4.6. pos_body_start()
74
+        4.7. pos_body_end()
66 75
 
67 76
 1. Overview
68 77
 
... ...
@@ -89,17 +98,34 @@ Chapter 1. Admin Guide
89 98
    running Kamailio with this module loaded:
90 99
      * none.
91 100
 
92
-3. Functions
101
+3. Parameters
102
+
103
+   3.1. idx0 (int)
104
+
105
+3.1. idx0 (int)
106
+
107
+   The value to return by functions seeking a position when the index is 0
108
+   (note: returning 0 is stopping the execution of configuration file like
109
+   'exit', but for KEMI usage it is ok).
110
+
111
+   Default value is -255.
112
+
113
+   Example 1.1. Set idx0 parameter
114
+...
115
+modparam("posops", "idx0", -200)
116
+...
117
+
118
+4. Functions
93 119
 
94
-   3.1. pos_append(idx, val)
95
-   3.2. pos_insert(idx, val)
96
-   3.3. pos_rm(idx, len)
97
-   3.4. pos_headers_start()
98
-   3.5. pos_headers_end()
99
-   3.6. pos_body_start()
100
-   3.7. pos_body_end()
120
+   4.1. pos_append(idx, val)
121
+   4.2. pos_insert(idx, val)
122
+   4.3. pos_rm(idx, len)
123
+   4.4. pos_headers_start()
124
+   4.5. pos_headers_end()
125
+   4.6. pos_body_start()
126
+   4.7. pos_body_end()
101 127
 
102
-3.1.  pos_append(idx, val)
128
+4.1.  pos_append(idx, val)
103 129
 
104 130
    Append the value val after the position idx in the SIP message buffer.
105 131
 
... ...
@@ -111,12 +137,12 @@ Chapter 1. Admin Guide
111 137
 
112 138
    This function can be used from ANY_ROUTE.
113 139
 
114
-   Example 1.1. pos_append() usage
140
+   Example 1.2. pos_append() usage
115 141
 ...
116 142
 pos_append("100", "kamailio-$si");
117 143
 ...
118 144
 
119
-3.2.  pos_insert(idx, val)
145
+4.2.  pos_insert(idx, val)
120 146
 
121 147
    Insert the value val at the position idx in the SIP message buffer.
122 148
 
... ...
@@ -128,12 +154,12 @@ pos_append("100", "kamailio-$si");
128 154
 
129 155
    This function can be used from ANY_ROUTE.
130 156
 
131
-   Example 1.2. pos_insert() usage
157
+   Example 1.3. pos_insert() usage
132 158
 ...
133 159
 pos_insert("100", "kamailio-$si");
134 160
 ...
135 161
 
136
-3.3.  pos_rm(idx, len)
162
+4.3.  pos_rm(idx, len)
137 163
 
138 164
    Remove len characters starting at the position idx in the SIP message
139 165
    buffer.
... ...
@@ -147,51 +173,51 @@ pos_insert("100", "kamailio-$si");
147 173
 
148 174
    This function can be used from ANY_ROUTE.
149 175
 
150
-   Example 1.3. pos_rm() usage
176
+   Example 1.4. pos_rm() usage
151 177
 ...
152 178
 pos_insert("100", "10");
153 179
 ...
154 180
 
155
-3.4.  pos_headers_start()
181
+4.4.  pos_headers_start()
156 182
 
157 183
    Return the position in the message buffer where headers start.
158 184
 
159 185
    This function can be used from ANY_ROUTE.
160 186
 
161
-   Example 1.4. pos_headers_start() usage
187
+   Example 1.5. pos_headers_start() usage
162 188
 ...
163 189
 $var(pos) = pos_headers_start();
164 190
 ...
165 191
 
166
-3.5.  pos_headers_end()
192
+4.5.  pos_headers_end()
167 193
 
168 194
    Return the position in the message buffer where headers end.
169 195
 
170 196
    This function can be used from ANY_ROUTE.
171 197
 
172
-   Example 1.5. pos_headers_end() usage
198
+   Example 1.6. pos_headers_end() usage
173 199
 ...
174 200
 $var(pos) = pos_headers_end();
175 201
 ...
176 202
 
177
-3.6.  pos_body_start()
203
+4.6.  pos_body_start()
178 204
 
179 205
    Return the position in the message buffer where body starts.
180 206
 
181 207
    This function can be used from ANY_ROUTE.
182 208
 
183
-   Example 1.6. pos_body_start() usage
209
+   Example 1.7. pos_body_start() usage
184 210
 ...
185 211
 $var(pos) = pos_body_start();
186 212
 ...
187 213
 
188
-3.7.  pos_body_end()
214
+4.7.  pos_body_end()
189 215
 
190 216
    Return the position in the message buffer where body ends.
191 217
 
192 218
    This function can be used from ANY_ROUTE.
193 219
 
194
-   Example 1.7. pos_body_end() usage
220
+   Example 1.8. pos_body_end() usage
195 221
 ...
196 222
 $var(pos) = pos_body_end();
197 223
 ...