1.

Explain XMLEventReader Class of StAX parser.

Answer»

This class provide iterator of events which can be used to iterate over events as they occur while parsing the XML document.

  • StartElement asStartElement() - used to retrieve value and attributes of element.

  • EndElement asEndElement() - called at the end of a element.

  • Characters asCharacters() - can be used to obtain characters such a CDATA, whitespace etc.



Discussion

No Comment Found