|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
public interface ElementVisitor
The ElementVisitor interface describes the implementation of a visitor pattern for GData data model processing.
Element.visit(ElementVisitor, ElementMetadata)
Nested Class Summary | |
---|---|
static class |
ElementVisitor.StoppedException
The StoppedException is thrown by ElementVisitor instances to immediately exit from element tree processing. |
Method Summary | |
---|---|
boolean |
visit(Element parent,
Element target,
ElementMetadata<?,?> metadata)
Called during Element tree traversal to allow the visitor instance to process an element in the tree. |
void |
visitComplete(Element parent,
Element target,
ElementMetadata<?,?> metadata)
The visitComplete method is called when traversal for an Element and all of its nested children has been completed. |
Method Detail |
---|
boolean visit(Element parent, Element target, ElementMetadata<?,?> metadata) throws ElementVisitor.StoppedException
parent
- the parent of the target elementtarget
- the target element being visitedmetadata
- the metadata for the target element
ElementVisitor.StoppedException
- if the data model traversal should be stopped
immediately. This may be the result of an unexpected error, or some
visitor implementations may extend this exception type to signal
specific exit conditions.void visitComplete(Element parent, Element target, ElementMetadata<?,?> metadata) throws ElementVisitor.StoppedException
parent
- the parent of the target elementtarget
- the visited elementmetadata
- the metadata for the target element
ElementVisitor.StoppedException
- if the data model traversal should be stopped
immediately. This may be the result of an unexpected error, or some
visitor implementations may extend this exception type to signal
specific exit conditions.
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |