Can you walk us through the steps necessary to parse XML
documents?
Answers were Sorted based on User's Feedback
Answer / chandrasekhar
1.create a instance of DocumentBuilderFactory Object using
newInstance() method.
2.get reference to DocumentBuilder object using
newDocumentBuilder() method of DocumentBuilderFactory.
3.get reference to Document object of the xml file to be
parsed by using DocumentBuilder.parse(File xmlfile) with
File object as argument.
start using Document object to get the elements of the xml
file using getElementsByTagName(),getElementsByName()
| Is This Answer Correct ? | 7 Yes | 0 No |
Answer / guest
Superficially, this is a fairly basic question. However, the
ball is not to determine whether candidates understand the
concept of a parser but rather have them walk through the
process of parsing XML documents step-by-step. Determining
whether a non-validating or validating parser is needed,
choosing the appropriate parser, and handling errors are all
important aspects to this process that should be included in
the candidate's response.
| Is This Answer Correct ? | 4 Yes | 0 No |
Using XSLT, how would you extract a specific attribute from an element in an XML document?
Do rss feeds help seo?
Do you know why we use select="@|node()" in the <xsl:apply-templates/> element on Identity template? What will happen if we use <xsl:apply-templates/> without select attribute?
How do I subscribe to an rss feed on my iphone?
what is 'parser'?
How to run an xml file?
Why is xml extensible?
What is an xml map?
What is a podcast rss feed?
Who developed xml?
What is excel xml format?
Is docx a zip file?