Module: sip-router Branch: master Commit: fe6508d6d56a7f739c7fc0ae2220e509abb337e1 URL: http://git.sip-router.org/cgi-bin/gitweb.cgi/sip-router/?a=commit;h=fe6508d6...
Author: Olle E. Johansson oej@edvina.net Committer: Olle E. Johansson oej@edvina.net Date: Sat Dec 1 10:49:11 2012 +0100
sdpops: Typo fix, minor edits
---
modules/sdpops/README | 55 ++++++++++++++++++----------------- modules/sdpops/doc/sdpops_admin.xml | 25 ++++++++------- 2 files changed, 41 insertions(+), 39 deletions(-)
diff --git a/modules/sdpops/README b/modules/sdpops/README index 7556c42..88f8c86 100644 --- a/modules/sdpops/README +++ b/modules/sdpops/README @@ -86,9 +86,9 @@ Chapter 1. Admin Guide payloads of SIP messages.
Examples of functions this module offers: remove codecs from SDP, check - the media stream types, return attributes of SDP document. For the full - list of the features provided by this module and the implementation - state, read the list of exported functions. + the media stream types and return attributes of SDP document. For the + full list of the features provided by this module and the + implementation state, please read the list of exported functions.
2. Dependencies
@@ -125,11 +125,11 @@ Chapter 1. Admin Guide 4.11. sdp_get(avpvar) 4.12. sdp_content()
-4.1. sdp_remove_codecs_by_id(list) +4.1. sdp_remove_codecs_by_id(list)
Remove the codecs provided in the parameter 'list' from all media - streams found in SDP payload. The parameter 'list' must be one or a - comma separated list of numeric codec IDs. The parameter can be a + streams found in SDP payload. The parameter 'list' must be one item or + a comma separated list of numeric codec IDs. The parameter can be a static string or a variable holding the list of numeric codec IDs.
This function can be used from ANY_ROUTE. @@ -142,11 +142,11 @@ sdp_remove_codecs_by_id("0"); sdp_remove_codecs_by_id("0,8,3"); ...
-4.2. sdp_remove_codecs_by_name(list) +4.2. sdp_remove_codecs_by_name(list)
Remove the codecs provided in the parameter 'list' from all media - streams found in SDP payload. The parameter 'list' must be one or a - comma separated list of codec names. The parameter can be a static + streams found in SDP payload. The parameter 'list' must be one item or + a comma separated list of codec names. The parameter can be a static string or a variable holding the list of codec names.
This function can be used from ANY_ROUTE. @@ -159,15 +159,16 @@ sdp_remove_codecs_by_name("PCMU"); sdp_remove_codecs_by_name("PCMU,PCMA,GSM"); ...
-4.3. sdp_remove_line_by_prefix(string) +4.3. sdp_remove_line_by_prefix(string)
- Remove all SDP attribute lines beginning with 'string'. + Remove all SDP attribute lines beginning with 'string' in all media + streams.
This function can be used from ANY_ROUTE.
Example 1.3. sdp_remove_line_by_prefix usage ... -if ($si == "1080::8:800:200C:417A" +if ($si == "2001:DB8::8:800:200C:417A" and ( has_body("application/sdp") or has_body("multipart/mixed"))) { xlog("L_INFO", "Cleaning ugly SDP from $si\n"); @@ -177,11 +178,11 @@ if ($si == "1080::8:800:200C:417A"
...
-4.4. sdp_keep_codecs_by_id(list [, mtype]) +4.4. sdp_keep_codecs_by_id(list [, mtype])
Keep only the codecs provided in the parameter 'list' from all media - streams found in SDP payload. The parameter 'list' must be one or a - comma separated list of numeric codec IDs. The parameter can be a + streams found in SDP payload. The parameter 'list' must be one item or + a comma separated list of numeric codec IDs. The parameter can be a static string or a variable holding the list of numeric codec IDs.
Optional parameter mtype can be provided to apply the operations only @@ -197,7 +198,7 @@ sdp_keep_codecs_by_id("0"); sdp_keep_codecs_by_id("0,8,3", "audio"); ...
-4.5. sdp_keep_codecs_by_name(list [, mtype]) +4.5. sdp_keep_codecs_by_name(list [, mtype])
Keep only the codecs provided in the parameter 'list' from all media streams found in SDP payload. The parameter 'list' must be one or a @@ -217,7 +218,7 @@ sdp_keep_codecs_by_name("PCMU"); sdp_keep_codecs_by_name("PCMU,PCMA,GSM"); ...
-4.6. sdp_with_media(type) +4.6. sdp_with_media(type)
Return true of the SDP has 'media=type ...' line. Useful to check the content of the RTP sessions, such as 'audio' or 'video'. The parameter @@ -234,7 +235,7 @@ if(sdp_with_media("video")) } ...
-4.7. sdp_remove_media(type) +4.7. sdp_remove_media(type)
Remove the streams that match on 'm=type ...' line. The parameter can be static string or variable holding the media type. @@ -247,7 +248,7 @@ if(sdp_with_media("video")) sdp_remove_media("video"); ...
-4.8. sdp_with_codecs_by_id(list) +4.8. sdp_with_codecs_by_id(list)
Returns true if any of the codecs provided in the parameter 'list' from all media streams is found in SDP payload. The parameter 'list' must be @@ -264,24 +265,24 @@ if(sdp_with_codecs_by_id("0")) { ... } if(sdp_with_codecs_by_id("0,8,3")) { ... } ...
-4.9. sdp_with_codecs_by_name(list) +4.9. sdp_with_codecs_by_name(list)
Returns true if any of the codecs provided in the parameter 'list' from all media streams is found in SDP payload. The parameter 'list' must be - one or a comma separated list of codec names. The parameter can be a - static string or a variable holding the list of codec names. + one item or a comma separated list of codec names. The parameter can be + a static string or a variable holding the list of codec names.
This function can be used from ANY_ROUTE.
Example 1.9. sdp_with_codecs_by_name usage ... # test for PCMU -if(sdp_with_codecs_by_id("PCMU")) { ... } +if(sdp_with_codecs_by_name("PCMU")) { ... } # test for PCMU, PCMA or GSM -if(sdp_with_codecs_by_id("PCMU,PCMA,GSM")) { ... } +if(sdp_with_codecs_by_name("PCMU,PCMA,GSM")) { ... } ...
-4.10. sdp_print(level) +4.10. sdp_print(level)
Print the SDP internal structure to log 'level'. The parameter can be static integer or variable holding the integer value of the log level. @@ -294,7 +295,7 @@ if(sdp_with_codecs_by_id("PCMU,PCMA,GSM")) { ... } sdp_print("1"); ...
-4.11. sdp_get(avpvar) +4.11. sdp_get(avpvar)
Store the SDP part of message body in an AVP. Return 1 if SDP is found, -1 on error and -2 if there is no SDP part in the message body. @@ -306,7 +307,7 @@ sdp_print("1"); sdp_get("$avp(sdp)"); ...
-4.12. sdp_content() +4.12. sdp_content()
Return true if the SIP message has SDP body or a SDP part in body.
diff --git a/modules/sdpops/doc/sdpops_admin.xml b/modules/sdpops/doc/sdpops_admin.xml index b816c89..831669e 100644 --- a/modules/sdpops/doc/sdpops_admin.xml +++ b/modules/sdpops/doc/sdpops_admin.xml @@ -16,14 +16,14 @@ <section> <title>Overview</title> <para> - This module provides functions for checking and managing the SDP - payloads of SIP messages. + This module provides functions for checking and managing the + <acronym>SDP</acronym> payloads of SIP messages. </para> <para> Examples of functions this module offers: remove codecs from SDP, - check the media stream types, return attributes of SDP document. + check the media stream types and return attributes of SDP document. For the full list of the features provided by this module and - the implementation state, read the list of exported functions. + the implementation state, please read the list of exported functions. </para> </section>
@@ -73,7 +73,7 @@ <para> Remove the codecs provided in the parameter 'list' from all media streams found in SDP payload. The parameter 'list' must - be one or a comma separated list of numeric codec IDs. The + be one item or a comma separated list of numeric codec IDs. The parameter can be a static string or a variable holding the list of numeric codec IDs. </para> @@ -99,7 +99,7 @@ sdp_remove_codecs_by_id("0,8,3"); <para> Remove the codecs provided in the parameter 'list' from all media streams found in SDP payload. The parameter 'list' must - be one or a comma separated list of codec names. The + be one item or a comma separated list of codec names. The parameter can be a static string or a variable holding the list of codec names. </para> @@ -123,7 +123,8 @@ sdp_remove_codecs_by_name("PCMU,PCMA,GSM"); <function moreinfo="none">sdp_remove_line_by_prefix(string)</function> </title> <para> - Remove all SDP attribute lines beginning with 'string'. + Remove all SDP attribute lines beginning with 'string' + in all media streams. </para> <para> This function can be used from ANY_ROUTE. @@ -132,7 +133,7 @@ sdp_remove_codecs_by_name("PCMU,PCMA,GSM"); <title><function>sdp_remove_line_by_prefix</function> usage</title> <programlisting format="linespecific"> ... -if ($si == "1080::8:800:200C:417A" +if ($si == "2001:DB8::8:800:200C:417A" and ( has_body("application/sdp") or has_body("multipart/mixed"))) { xlog("L_INFO", "Cleaning ugly SDP from $si\n"); @@ -151,7 +152,7 @@ if ($si == "1080::8:800:200C:417A" <para> Keep only the codecs provided in the parameter 'list' from all media streams found in SDP payload. The parameter 'list' must - be one or a comma separated list of numeric codec IDs. The + be one item or a comma separated list of numeric codec IDs. The parameter can be a static string or a variable holding the list of numeric codec IDs. </para> @@ -283,7 +284,7 @@ if(sdp_with_codecs_by_id("0,8,3")) { ... } <para> Returns true if any of the codecs provided in the parameter 'list' from all media streams is found in SDP payload. The parameter - 'list' must be one or a comma separated list of codec names. + 'list' must be one item or a comma separated list of codec names. The parameter can be a static string or a variable holding the list of codec names. </para> @@ -295,9 +296,9 @@ if(sdp_with_codecs_by_id("0,8,3")) { ... } <programlisting format="linespecific"> ... # test for PCMU -if(sdp_with_codecs_by_id("PCMU")) { ... } +if(sdp_with_codecs_by_name("PCMU")) { ... } # test for PCMU, PCMA or GSM -if(sdp_with_codecs_by_id("PCMU,PCMA,GSM")) { ... } +if(sdp_with_codecs_by_name("PCMU,PCMA,GSM")) { ... } ... </programlisting> </example>