Module l2dbus.xml

XML Module.

The original classic (software-only) XML parser by Roberto Ierusalimschy. Modifications to parser by Steve Donovan with additional helper functions taken from Penlight's XML module.

Known Limitations:

  • Does not support embedded XML comments.

Functions

parse (s, all_text) Parses an XML string and builds a document tree containing child tags.

Doc

childtags () Returns the child tags of the XML document.


Functions

parse (s, all_text)
Parses an XML string and builds a document tree containing child tags.

A very basic XML parser that can be used to parse D-Bus XML introspection data for services. The returned Doc object only provides the APIs necessary to extract the child tags from the document object.

Parameters:

  • s string The XML string to parse.
  • all_text bool If true it preserves all whitespace otherwise only text containing non-whitespace is included. Default value is false.

Returns:

    table A Doc object with a method to retrieve the document tags.

Doc

childtags ()
Returns the child tags of the XML document.

The returned child tags themselves are XML (Doc) documents that can themselves be queried for child tags.

Returns:

    table An array of child tags which are themselves documents.
generated by LDoc 1.3