Package nu.validator.saxtree
package nu.validator.saxtree
This package provides SAX Tree: a tree model optimized for creation from SAX events and replay as SAX events.
Design Principles
- Preserve information exposed through
ContentHandler
,LexicalHandler
andLocator
. - Creation from SAX events or as part of the parse of a conforming HTML5 document should be fast.
- Emitting SAX events based on the tree should be fast.
- Mutations should be possible but should not make the above "fast" cases slower.
- Concurrent reads should work without locking when there are no concurrent mutations.
- The user of the API has the responsibility of using the API properly: for the sake of performance, the model does not check if it is being used properly. Improper use may, therefore, put the model in and inconsistent state.
-
ClassDescriptionA CDATA section.A run of charactersA common superclass for character buffer node classes.A comment.A document.A document fragment.A doctype.An element.An entity.A run ignorable whitespace.A locator implementation.The common node superclass.The node type.A lexical handler that does nothing.Common superclass for parent nodes.A prefix mapping.A processing instruction.A skipped entity.Builds a SAX Tree representation of a document or a fragment streamed as
ContentHandler
andLexicalHandler
events.A tree visitor that replays a tree as SAX events.