SAX Examples

From NovaOrdis Knowledge Base
Revision as of 03:12, 10 November 2016 by Ovidiu (talk | contribs) (→‎Location in an XML Document)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to navigation Jump to search

External

Internal

Simple Parsing

https://github.com/NovaOrdis/playground/tree/master/java/xml/sax

Location in an XML Document

The SAX parser provide document location information via an org.xml.sax.Locator implementation, injected into the ContentHandler with:

public void setDocumentLocator(Locator locator) {
    ...
}

Full example:

https://github.com/NovaOrdis/playground/tree/master/java/xml/sax-location

DTD and XML Schema Validation

TODO: https://docs.oracle.com/javase/tutorial/jaxp/sax/validation.html