You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
sems/doc/dsm/mods
Stefan Sayer 8c0a4b6679
DSM:mod_dlg: added setting errno if dlg.acceptInvite fails
14 years ago
..
Readme.mod_aws.txt moved DSM module docs to doc directory 16 years ago
Readme.mod_conference.txt dsm: fix typo in doc 16 years ago
Readme.mod_curl.txt DSM: mod_curl module to retrieve http pages, files, use rest APIs etc 14 years ago
Readme.mod_dlg.txt DSM:mod_dlg: added setting errno if dlg.acceptInvite fails 14 years ago
Readme.mod_groups.txt DSM: groups module 16 years ago
Readme.mod_monitoring.txt moved DSM module docs to doc directory 16 years ago
Readme.mod_mysql.txt dsm:mod_mysql: mysql.playDBAudioFront and mysql.playDBAudioLooped actions 14 years ago
Readme.mod_py.txt moved DSM module docs to doc directory 16 years ago
Readme.mod_regex.txt dsm: mod_regex module for regular expressions in DSM 15 years ago
Readme.mod_subscription.txt RFC3265 Event notification (SUBSCRIBE/NOTIFY) support - SEMS as susbcriber 14 years ago
Readme.mod_sys.txt DSM: sys.getTimestamp() and sys.subTimestamp() 16 years ago
Readme.mod_uri.txt moved DSM module docs to doc directory 16 years ago
Readme.mod_utils.txt dsm: adds utils.playRingTone() function 16 years ago
Readme.mod_xml.txt DSM: mod_xml: libxml logging to SEMS log, added xml.setLogLevel function 14 years ago

Readme.mod_xml.txt

mod_xml - generic XML functions

This module implements generic XML handling functions. XML objects are created in
objects, which must be tracked or released by the script using trackObject/freeObject.
Then functions can be executed on the XML objects, e.g. XPath evaluation.

mod_xml must be preloaded to initialize libxml2.

xml.parse("<xml_obj/>", dst_objname)
  parse XML string into object referenced with dst_objname.
  Example: xml.parse($myxml, xml_obj)

xml.parseSIPMsgBody(msg_body_object, dst_objname)
  Parse a SIP message body object into an XML object.
  Example: xml.parseSIPMsgBody("SipSubscriptionBody", "substatus")

xml.evalXPath(xpath_expr, xml_object)
  Evaluate XPath expression on XML object.
  Namespaces are registered in $xml_object.ns variable.
  The result is saved to xml_object.xpath object.
  Example: 
    set($substatus.ns="a=urn:ietf:params:xml:ns:reginfo")
    xml.evalXPath("//a:contact[@state='active']", "substatus");

xml.XPathResultCount($cntvar=xpath_object)
  Save result count of XPath result in xpath_object into counter variable $cntvar.
  Example:
    xml.XPathResultCount($rescnt="substatus.xpath");

xml.setLoglevel(level)
 set libxml2 error logging level. Default: error
 Valid: error, warn, info, debug