|
|
 |
|
|
| NOTE: This Design document is subject to change at any time. |
zApp contains a powerful XML parsing library that is available to any scripting language. This allows you to use the scripting language of your choice based upon familiar syntax rather than because of which language contains which function.
The functions in the XML library are accessed via the built-in xml object name. For example, in VBScript or Javascript, you would access the LoadFile function using the notation xml.LoadFile. In Perl, this syntax would be $xml->LoadFile.
The XML library contains routines to parse XML files in two different ways. The SAX (Simple XML Parser) (http://www.saxproject.org/) and DOM (Document Object Model) (http://www.w3.org/DOM/) tree-based parsing.
In SAX parsing, you use the xml.Parse or xml.ParseFile functions to load an XML document and call various Event routines as the file is being parsed. The document is not stored in memory.
In DOM parsing, you use the xml.Load or xml.LoadFile functions to load an XML document into memory and create the tree-structure for that document. A zXML object is returned which has properties and functions that can be used to traverse the tree. You can also use the DOM model to create a new XML document from scratch and then save it to a file using the zxml.SaveFile function.
Select a function from the list on the left for more information on it. |
|