visitor library
Classes
-
GeneralizingElementVisitor<R>
-
An element visitor that will recursively visit all of the elements in an
element model (like instances of the class RecursiveElementVisitor). In
addition, when an element of a specific type is visited not only will the
visit method for that specific type of element be invoked, but additional
methods for the supertypes of that element will also be invoked. For
example, using an instance of this class to visit a MethodElement will
cause the method visitMethodElement to be invoked but will also cause the
methods visitExecutableElement and visitElement to be subsequently
invoked. This allows visitors to be written that visit all executable
elements without needing to override the visit method for each of the
specific subclasses of ExecutableElement. [...]
-
RecursiveElementVisitor<R>
-
A visitor that will recursively visit all of the element in an element
model. For example, using an instance of this class to visit a
CompilationUnitElement will also cause all of the types in the compilation
unit to be visited. [...]
-
SimpleElementVisitor<R>
-
A visitor that will do nothing when visiting an element. It is intended to
be a superclass for classes that use the visitor pattern primarily as a
dispatch mechanism (and hence don't need to recursively visit a whole
structure) and that only need to visit a small number of element types. [...]
-
ThrowingElementVisitor<R>
-
An AST visitor that will throw an exception if any of the visit methods that
are invoked have not been overridden. It is intended to be a superclass for
classes that implement the visitor pattern and need to (a) override all of
the visit methods or (b) need to override a subset of the visit method and
want to catch when any other visit methods have been invoked. [...]