FileDocCategorySizeDatePackage
TreeVisitor.javaAPI DocJava SE 6 API4010Tue Jun 10 00:23:26 BST 2008com.sun.source.tree

TreeVisitor

public interface TreeVisitor
A visitor of trees, in the style of the visitor design pattern. Classes implementing this interface are used to operate on a tree when the kind of tree is unknown at compile time. When a visitor is passed to an tree's {@link Tree#accept accept} method, the visitXYZ method most applicable to that tree is invoked.

Classes implementing this interface may or may not throw a {@code NullPointerException} if the additional parameter {@code p} is {@code null}; see documentation of the implementing class for details.

WARNING: It is possible that methods will be added to this interface to accommodate new, currently unknown, language structures added to future versions of the Java™ programming language. Therefore, visitor classes directly implementing this interface may be source incompatible with future versions of the platform.

param
the return type of this visitor's methods. Use {@link Void} for visitors that do not need to return results.
param

the type of the additional parameter to this visitor's methods. Use {@code Void} for visitors that do not need an additional parameter.

author
Peter von der Ahé
author
Jonathan Gibbons
since
1.6

Fields Summary
Constructors Summary
Methods Summary
public RvisitAnnotation(com.sun.source.tree.AnnotationTree node, P p)

public RvisitArrayAccess(com.sun.source.tree.ArrayAccessTree node, P p)

public RvisitArrayType(com.sun.source.tree.ArrayTypeTree node, P p)

public RvisitAssert(com.sun.source.tree.AssertTree node, P p)

public RvisitAssignment(com.sun.source.tree.AssignmentTree node, P p)

public RvisitBinary(com.sun.source.tree.BinaryTree node, P p)

public RvisitBlock(com.sun.source.tree.BlockTree node, P p)

public RvisitBreak(com.sun.source.tree.BreakTree node, P p)

public RvisitCase(com.sun.source.tree.CaseTree node, P p)

public RvisitCatch(com.sun.source.tree.CatchTree node, P p)

public RvisitClass(com.sun.source.tree.ClassTree node, P p)

public RvisitCompilationUnit(com.sun.source.tree.CompilationUnitTree node, P p)

public RvisitCompoundAssignment(com.sun.source.tree.CompoundAssignmentTree node, P p)

public RvisitConditionalExpression(com.sun.source.tree.ConditionalExpressionTree node, P p)

public RvisitContinue(com.sun.source.tree.ContinueTree node, P p)

public RvisitDoWhileLoop(com.sun.source.tree.DoWhileLoopTree node, P p)

public RvisitEmptyStatement(com.sun.source.tree.EmptyStatementTree node, P p)

public RvisitEnhancedForLoop(com.sun.source.tree.EnhancedForLoopTree node, P p)

public RvisitErroneous(com.sun.source.tree.ErroneousTree node, P p)

public RvisitExpressionStatement(com.sun.source.tree.ExpressionStatementTree node, P p)

public RvisitForLoop(com.sun.source.tree.ForLoopTree node, P p)

public RvisitIdentifier(com.sun.source.tree.IdentifierTree node, P p)

public RvisitIf(com.sun.source.tree.IfTree node, P p)

public RvisitImport(com.sun.source.tree.ImportTree node, P p)

public RvisitInstanceOf(com.sun.source.tree.InstanceOfTree node, P p)

public RvisitLabeledStatement(com.sun.source.tree.LabeledStatementTree node, P p)

public RvisitLiteral(com.sun.source.tree.LiteralTree node, P p)

public RvisitMemberSelect(com.sun.source.tree.MemberSelectTree node, P p)

public RvisitMethod(com.sun.source.tree.MethodTree node, P p)

public RvisitMethodInvocation(com.sun.source.tree.MethodInvocationTree node, P p)

public RvisitModifiers(com.sun.source.tree.ModifiersTree node, P p)

public RvisitNewArray(com.sun.source.tree.NewArrayTree node, P p)

public RvisitNewClass(com.sun.source.tree.NewClassTree node, P p)

public RvisitOther(com.sun.source.tree.Tree node, P p)

public RvisitParameterizedType(com.sun.source.tree.ParameterizedTypeTree node, P p)

public RvisitParenthesized(com.sun.source.tree.ParenthesizedTree node, P p)

public RvisitPrimitiveType(com.sun.source.tree.PrimitiveTypeTree node, P p)

public RvisitReturn(com.sun.source.tree.ReturnTree node, P p)

public RvisitSwitch(com.sun.source.tree.SwitchTree node, P p)

public RvisitSynchronized(com.sun.source.tree.SynchronizedTree node, P p)

public RvisitThrow(com.sun.source.tree.ThrowTree node, P p)

public RvisitTry(com.sun.source.tree.TryTree node, P p)

public RvisitTypeCast(com.sun.source.tree.TypeCastTree node, P p)

public RvisitTypeParameter(com.sun.source.tree.TypeParameterTree node, P p)

public RvisitUnary(com.sun.source.tree.UnaryTree node, P p)

public RvisitVariable(com.sun.source.tree.VariableTree node, P p)

public RvisitWhileLoop(com.sun.source.tree.WhileLoopTree node, P p)

public RvisitWildcard(com.sun.source.tree.WildcardTree node, P p)