net.sf.saxon.tinytree
Class TinyTreeEventIterator
java.lang.Object
net.sf.saxon.tinytree.TinyTreeEventIterator
- EventIterator, PullEvent
public class TinyTreeEventIterator
extends java.lang.Object
This implementation of the Saxon event-pull interface starts from a document, element,
text, comment, or processing-instruction node in a TinyTree,
and returns the events corresponding to that node and its descendants (including
their attributes and namespaces). The class performs the same function as
the general-purpose
Decomposer
class, but is
specialized to exploit the TinyTree data structure: in particular, it never
materializes any Node objects.
boolean | isFlatSequence() - Determine whether the EventIterator returns a flat sequence of events, or whether it can return
nested event iterators
|
PullEvent | next() - Get the next event
|
TinyTreeEventIterator
public TinyTreeEventIterator(TinyNodeImpl startNode)
Create a TinyTreeEventIterator to return events associated with a tree or subtree
startNode
- the root of the tree or subtree. Must be a document or element node.
isFlatSequence
public boolean isFlatSequence()
Determine whether the EventIterator returns a flat sequence of events, or whether it can return
nested event iterators
- isFlatSequence in interface EventIterator
- true if the next() method is guaranteed never to return an EventIterator