comet.xmltree¶
Reading XML files or strings for XML queries.
Methods¶
- comet.xmltree.open(path, useTreeBuffer=True)¶
Open an XML free from a file
- Parameters
path (str) –
The full path to the XML file.
In XML offline, SOAP and AEM® connections, XML configuration data such as panelstatements.xml and actions.xml can also be read here.
useTreeBuffer (bool) –
Reading XML files can be time-consuming.
Read files can therefore be buffered.
Buffered XML data is deleted when the connection is disconnected.
- Returns
The tree loaded from the file
- Return type
- Raises
TypeError – When parameter types are invalid
ValueError – When parameter path is empty
CometError – On internal error
- Available
- CScript
- comet.xmltree.parse(input)¶
Parse an XML Tree from an input string
- Parameters
input (str) – The input XML string
- Returns
The tree loaded from the string
- Return type
- Raises
TypeError – When parameter types are invalid
When parameter input is empty
When the input could not be parsed
CometError – On internal error