Kaynağa Gözat

new example: serctl fifo ul_show_contact

Jiri Kuthan 23 yıl önce
ebeveyn
işleme
eb83d33d96
1 değiştirilmiş dosya ile 23 ekleme ve 6 silme
  1. 23 6
      doc/seruser/seruser.sgml

+ 23 - 6
doc/seruser/seruser.sgml

@@ -3481,16 +3481,33 @@ print
 		<example>
 		<example>
 		    <title>FIFO Errors</title>
 		    <title>FIFO Errors</title>
 		    <programlisting format="linespecific">
 		    <programlisting format="linespecific">
-[jiri@cat sip_router]$ sc fifo foobar
+[jiri@cat sip_router]$ serctl fifo foobar
 500 command 'foobar' not available
 500 command 'foobar' not available
 		    </programlisting>
 		    </programlisting>
 		</example>
 		</example>
+
+		<example>
+			<title>Showing User Contacts Using serctl</title>
+			<para>
+			Another example of use of FIFO is accessing server's
+			in-memory user location database. That's a very powerful
+			feature: web applications and other tools can use it
+			to gain users access to the database. They can add new
+			contacts (like permanent gateway destinations), remove
+			and review their whereabouts. The example here utilizes
+			FIFO command <command>ul_show_contact</command> to
+			retrieve current whereabouts of user "jiri".
+			<programlisting>
+[jiri@fox ser]$ serctl fifo ul_show_contact location jiri
+<sip:195.37.78.160:14519>;q=0.00;expires=1012
+			</programlisting>
+		</example>
 	    </para>
 	    </para>
 	    <para>
 	    <para>
-		A powerful feature of the FIFO server is the ability to
-		export new commands from modules
-		for use by external 
-		applications. Currently, usrloc module exports FIFO
+		The user location example demonstrates an essential feature
+		of the FIFO server: extensibility. It is able to export new 
+		commands implemented in new modules.
+		Currently, usrloc module exports FIFO
 		commands for maintaining in-memory user location
 		commands for maintaining in-memory user location
 		database and tm module exports FIFO commands for
 		database and tm module exports FIFO commands for
 		management of SIP transactions. See the 
 		management of SIP transactions. See the 
@@ -3535,7 +3552,7 @@ EOF
 	    <example>
 	    <example>
 		<title>Manipulation of User Contacts</title>
 		<title>Manipulation of User Contacts</title>
 		<para>
 		<para>
-		    The following example shows use of FIFO server to manipulate
+		    The following example shows use of FIFO server to change 
 		    user's contacts. This may be very practical, if for example
 		    user's contacts. This may be very practical, if for example
 		    a user wishes to set up his cell phone number as his temporary
 		    a user wishes to set up his cell phone number as his temporary
 		    contact. The cell phone, which is behind a PSTN gateway, cannot
 		    contact. The cell phone, which is behind a PSTN gateway, cannot