Przeglądaj źródła

modules/sipt: finalise $sipt_event_info support

Torrey Searle 11 lat temu
rodzic
commit
a42976948e
3 zmienionych plików z 41 dodań i 1 usunięć
  1. 18 0
      modules/sipt/README
  2. 22 0
      modules/sipt/doc/sipt_admin.xml
  3. 1 1
      modules/sipt/sipt.c

+ 18 - 0
modules/sipt/README

@@ -27,6 +27,7 @@ Torrey Searle
               4.4. $sipt_cpc
               4.4. $sipt_cpc
               4.5. $sipt_calling_party_nai
               4.5. $sipt_calling_party_nai
               4.6. $sipt_called_party_nai
               4.6. $sipt_called_party_nai
+              4.7. $sipt_event_info
 
 
    List of Tables
    List of Tables
 
 
@@ -34,6 +35,7 @@ Torrey Searle
    1.2. Screening Indicator Values
    1.2. Screening Indicator Values
    1.3. Calling Nature of Address Values
    1.3. Calling Nature of Address Values
    1.4. Called Nature of Address Values
    1.4. Called Nature of Address Values
+   1.5. Event Info Values
 
 
    List of Examples
    List of Examples
 
 
@@ -65,6 +67,7 @@ Chapter 1. Admin Guide
         4.4. $sipt_cpc
         4.4. $sipt_cpc
         4.5. $sipt_calling_party_nai
         4.5. $sipt_calling_party_nai
         4.6. $sipt_called_party_nai
         4.6. $sipt_called_party_nai
+        4.7. $sipt_event_info
 
 
 1. Overview
 1. Overview
 
 
@@ -121,6 +124,7 @@ sipt_set_calling($fU, 4, 0, 3);
    4.4. $sipt_cpc
    4.4. $sipt_cpc
    4.5. $sipt_calling_party_nai
    4.5. $sipt_calling_party_nai
    4.6. $sipt_called_party_nai
    4.6. $sipt_called_party_nai
+   4.7. $sipt_event_info
 
 
 4.1. $sipt_presentation
 4.1. $sipt_presentation
 
 
@@ -244,3 +248,17 @@ if($sipt_called_party_nai == 3)
 }
 }
 
 
 ...
 ...
+
+4.7. $sipt_event_info
+
+   Returns the value of the Event Info header of the CPG message. Returns
+   -1 if there is a parsing error.
+
+   Table 1.5. Event Info Values
+   0 Spare
+   1 ALERTING
+   2 PROGRESS
+   3 In-band information or an appropriate pattern is now available
+   4 Call forward on busy
+   5 Call forward on no reply
+   6 Call forward unconditional

+ 22 - 0
modules/sipt/doc/sipt_admin.xml

@@ -251,6 +251,28 @@ if($sipt_called_party_nai == 3)
 </programlisting>
 </programlisting>
 		</example>
 		</example>
 	</section>
 	</section>
+	<section id="sipt.v.sipt_event_info">
+		<title><varname>$sipt_event_info</varname></title>
+		<para>
+			Returns the value of the Event Info header
+			of the CPG message.
+			Returns -1 if there is a parsing error.
+		</para>
+		<table>
+			<title>Event Info Values</title>
+			<tgroup cols="2">
+				<tbody>
+					<row><entry>0</entry><entry>Spare</entry></row>
+					<row><entry>1</entry><entry>ALERTING</entry></row>
+					<row><entry>2</entry><entry>PROGRESS</entry></row>
+					<row><entry>3</entry><entry>In-band information or an appropriate pattern is now available</entry></row>
+					<row><entry>4</entry><entry>Call forward on busy</entry></row>
+					<row><entry>5</entry><entry>Call forward on no reply</entry></row>
+					<row><entry>6</entry><entry>Call forward unconditional</entry></row>
+				</tbody>
+			</tgroup>
+		</table>
+	</section>
 
 
 </section>
 </section>
 </chapter>
 </chapter>

+ 1 - 1
modules/sipt/sipt.c

@@ -104,7 +104,7 @@ static pv_export_t mod_items[] = {
                 0, 0, 0, 0 },
                 0, 0, 0, 0 },
         { {"sipt_hop_counter",  sizeof("sipt_hop_counter")-1}, PVT_OTHER,  sipt_get_hop_counter,    0,
         { {"sipt_hop_counter",  sizeof("sipt_hop_counter")-1}, PVT_OTHER,  sipt_get_hop_counter,    0,
                 0, 0, 0, 0 },
                 0, 0, 0, 0 },
-        { {"sipt_event_info",  sizeof("sipt_cpc")-1}, PVT_OTHER,  sipt_get_event_info,    0,
+        { {"sipt_event_info",  sizeof("sipt_event_info")-1}, PVT_OTHER,  sipt_get_event_info,    0,
                 0, 0, 0, 0 },
                 0, 0, 0, 0 },
         { {"sipt_cpc",  sizeof("sipt_cpc")-1}, PVT_OTHER,  sipt_get_cpc,    0,
         { {"sipt_cpc",  sizeof("sipt_cpc")-1}, PVT_OTHER,  sipt_get_cpc,    0,
                 0, 0, 0, 0 },
                 0, 0, 0, 0 },