PI can be used for inserting non-XML statements, such as scripts, into the document, to be passed to an application for processing.
There are two standard APIs for parsing XML documents: API.
The SAX API defines a number of callback methods, which will be called when events occur during parsing.
A well-formed XML document exhibits a tree-like structure, and can be processed by an XML processor.
For example, the tree structure of the "bookstore.xml" is as follows: An XML document comprises of the following basic units: to XML parser or an application program that uses the XML document.
The SAX parser reads an XML document and generate events as it finds elements, attributes, or data in the document.