This topic explains how to build a DOM tree by parsing an XML file.
Before you start, you must:
put parser resources on the clean-up stack.
instance of the
by calling its
instance is the DOM Engine.
Initialise the DOM parser by calling the
on its instance.
parser.Open( impl );
You can also have several parsers registered on a DOM Engine instance.
Parse the specified XML file by calling the
RXmlDocument myDoc = parser.ParseFileL( "tutorial.xml" );
object is a DOM tree containing the data
from the XML file.
Use the created DOM tree.
For example, refer to the
a DOM Tree using XPath
to search for specific elements or attributes
in the DOM tree.
Free your resources as necessary.
Close the parser
and the engine by calling their
Close the XML library by calling the
This method also removes the serialisation resources from the clean-up stack.
Perform any other clean-up operations.
Copyright ©2010 Nokia Corporation and/or its subsidiary(-ies).
reserved. Unless otherwise stated, these materials are provided under the terms of the Eclipse Public License