Summary
The SAX XMLReader interface represents an XML parser. The actual implementation class will vary from one parser to the next, but generally you'll only interact with it through the parser-independent methods in XMLReader. Parser-specific instances of this interface are built by the XMLReaderFactory factory class.
The XMLReader's parse() method actually reads the XML document. One parser object can read multiple documents in series. However, parsers are neither thread safe nor reentrant and should not be used to read documents in parallel. The source from which the XML document is read—be it an InputStream, Reader, or URI—is wrapped inside an org.xml.sax.InputSource object. You can use an EntityResolver to replace one InputSource with a ...
Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.
Read now
Unlock full access