Package org.eclipse.cdt.core.dom.ast

# Class ASTGenericVisitor

java.lang.Object
org.eclipse.cdt.core.dom.ast.ASTVisitor
org.eclipse.cdt.core.dom.ast.ASTGenericVisitor

All Implemented Interfaces:
  `ICASTVisitor`, `ICPPASTVisitor`

public abstract class ASTGenericVisitor extends ASTVisitor implements ICPPASTVisitor, ICASTVisitor
Generic visitor for AST nodes.

Clients may subclass.

Since:
  5.1

## Field Summary

### Fields inherited from class org.eclipse.cdt.core.dom.ast.ASTVisitor

`includeInactiveNodes, PROCESS_ABORT, PROCESS_CONTINUE, PROCESS_SKIP, shouldVisitAmbiguousNodes, shouldVisitArrayModifiers, shouldVisitAttributes, shouldVisitBaseSpecifiers, shouldVisitCaptures, shouldVisitDeclarations, shouldVisitDeclarators, shouldVisitDeclSpecifiers, shouldVisitDecltypeSpecifiers, shouldVisitDesignators, shouldVisitEnumerators, shouldVisitExpressions, shouldVisitImplicitDestructorNames, shouldVisitImplicitNameAlternates, shouldVisitImplicitNames, shouldVisitInitializers, shouldVisitNames, shouldVisitNamespaces, shouldVisitParameterDeclarations, shouldVisitPointerOperators, shouldVisitProblems, shouldVisitStatements, shouldVisitTemplateParameters, shouldVisitTokens, shouldVisitTranslationUnit, shouldVisitTypeIds, shouldVisitVirtSpecifiers`

## Constructor Summary

Constructors
Constructor
Description
`ASTGenericVisitor(boolean visitNodes)`

## Method Summary

Modifier and Type
Method
Description
`protected int`
`genericLeave(IASTNode node)`
`protected int`
`genericVisit(IASTNode node)`
`int`
`leave(ICASTDesignator designator)`
Visits a designator.
`int`
`leave(ICPPASTCapture capture)`
`int`
`leave(ICPPASTCompositeTypeSpecifier.ICPPASTBaseSpecifier baseSpecifier)`
Visits a base class specifier of a composite type.
`int`
`leave(ICPPASTNamespaceDefinition namespaceDefinition)`
Visits a namespace definition.
`int`
`leave(ICPPASTTemplateParameter templateParameter)`
Visits a template parameter.
`int`
`leave(IASTArrayModifier arrayModifier)`
`int`
`leave(IASTDeclaration declaration)`
`int`
`leave(IASTDeclarator declarator)`
`int`
`leave(IASTDeclSpecifier declSpec)`
`int`
`leave(IASTEnumerationSpecifier.IASTEnumerator enumerator)`
`int`
`leave(IASTExpression expression)`
`int`
`leave(IASTInitializer initializer)`
`int`
`leave(IASTName name)`
`int`
`leave(IASTParameterDeclaration parameterDeclaration)`
`int`
`leave(IASTPointerOperator ptrOperator)`
`int`
`leave(IASTProblem problem)`
`int`
`leave(IASTStatement statement)`
`int`
`leave(IASTTranslationUnit tu)`
`int`
`leave(IASTTypeId typeId)`
`int`
`visit(ICASTDesignator designator)`
Visits a designator.
`int`
`visit(ICPPASTCapture capture)`
`int`
`visit(ICPPASTCompositeTypeSpecifier.ICPPASTBaseSpecifier baseSpecifier)`
Visits a base class specifier of a composite type.
`int`
`visit(ICPPASTNamespaceDefinition namespaceDefinition)`
Visits a namespace definition.
`int`
`visit(ICPPASTTemplateParameter templateParameter)`
Visits a template parameter.
`int`
`visit(IASTArrayModifier arrayModifier)`
`int`
`visit(IASTDeclaration declaration)`
`int`
`visit(IASTDeclarator declarator)`
`int`
`visit(IASTDeclSpecifier declSpec)`
`int`
`visit(IASTEnumerationSpecifier.IASTEnumerator enumerator)`
`int`
`visit(IASTExpression expression)`
`int`
`visit(IASTInitializer initializer)`
`int`
`visit(IASTName name)`
`int`
`visit(IASTParameterDeclaration parameterDeclaration)`
`int`
`visit(IASTPointerOperator ptrOperator)`
`int`
`visit(IASTProblem problem)`
`int`
`visit(IASTStatement statement)`
`int`
`visit(IASTTranslationUnit tu)`
`int`
`visit(IASTTypeId typeId)`

### Methods inherited from class org.eclipse.cdt.core.dom.ast.ASTVisitor

`leave, leave, leave, leave, leave, leave, leave, visit, visit, visit, visit, visit, visit, visit, visit`

### Methods inherited from class java.lang.Object

`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

## Constructor Details

### ASTGenericVisitor

public ASTGenericVisitor(boolean visitNodes)

## Method Details

### genericVisit

protected int genericVisit(IASTNode node)

### genericLeave

protected int genericLeave(IASTNode node)

### visit

public int visit(ICPPASTCompositeTypeSpecifier.ICPPASTBaseSpecifier baseSpecifier)
Description copied from interface: `ICPPASTVisitor`
Visits a base class specifier of a composite type.

Specified by:
  `visit` in interface `ICPPASTVisitor`
Overrides:
  `visit` in class `ASTVisitor`
Returns:
  `ASTVisitor.PROCESS_CONTINUE`, `ASTVisitor.PROCESS_SKIP` or `ASTVisitor.PROCESS_ABORT`

### visit

public int visit(ICPPASTNamespaceDefinition namespaceDefinition)
Description copied from interface: `ICPPASTVisitor`
Visits a namespace definition.

Specified by:
  `visit` in interface `ICPPASTVisitor`
Overrides:
  `visit` in class `ASTVisitor`
Returns:
  `ASTVisitor.PROCESS_CONTINUE`, `ASTVisitor.PROCESS_SKIP` or `ASTVisitor.PROCESS_ABORT`

### visit

public int visit(ICPPASTTemplateParameter templateParameter)
Description copied from interface: `ICPPASTVisitor`
Visits a template parameter.

Specified by:
  `visit` in interface `ICPPASTVisitor`
Overrides:
  `visit` in class `ASTVisitor`
Returns:
  `ASTVisitor.PROCESS_CONTINUE`, `ASTVisitor.PROCESS_SKIP` or `ASTVisitor.PROCESS_ABORT`

### visit

public int visit(ICPPASTCapture capture)

Overrides:
  `visit` in class `ASTVisitor`

### visit

public int visit(IASTArrayModifier arrayModifier)

Overrides:
  `visit` in class `ASTVisitor`

### visit

public int visit(IASTPointerOperator ptrOperator)

Overrides:
  `visit` in class `ASTVisitor`

### visit

public int visit(IASTDeclaration declaration)

Overrides:
  `visit` in class `ASTVisitor`

### visit

public int visit(IASTDeclarator declarator)

Overrides:
  `visit` in class `ASTVisitor`

### visit

public int visit(IASTDeclSpecifier declSpec)

Overrides:
  `visit` in class `ASTVisitor`

### visit

public int visit(IASTEnumerationSpecifier.IASTEnumerator enumerator)

Overrides:
  `visit` in class `ASTVisitor`

### visit

public int visit(IASTExpression expression)

Overrides:
  `visit` in class `ASTVisitor`

### visit

public int visit(IASTInitializer initializer)

Overrides:
  `visit` in class `ASTVisitor`

### visit

public int visit(IASTName name)

Overrides:
  `visit` in class `ASTVisitor`

### visit

public int visit(IASTParameterDeclaration parameterDeclaration)

Overrides:
  `visit` in class `ASTVisitor`

### visit

public int visit(IASTProblem problem)

Overrides:
  `visit` in class `ASTVisitor`

### visit

public int visit(IASTStatement statement)

Overrides:
  `visit` in class `ASTVisitor`

### visit

public int visit(IASTTranslationUnit tu)

Overrides:
  `visit` in class `ASTVisitor`

### visit

public int visit(IASTTypeId typeId)

Overrides:
  `visit` in class `ASTVisitor`

### visit

public int visit(ICASTDesignator designator)
Description copied from interface: `ICASTVisitor`
Visits a designator.

Specified by:
  `visit` in interface `ICASTVisitor`
Overrides:
  `visit` in class `ASTVisitor`
Returns:
  `ASTVisitor.PROCESS_CONTINUE`, `ASTVisitor.PROCESS_SKIP` or `ASTVisitor.PROCESS_ABORT`

### leave

public int leave(ICASTDesignator designator)
Description copied from interface: `ICASTVisitor`
Visits a designator.

Specified by:
  `leave` in interface `ICASTVisitor`
Overrides:
  `leave` in class `ASTVisitor`
Returns:
  `ASTVisitor.PROCESS_CONTINUE` or `ASTVisitor.PROCESS_ABORT`

### leave

public int leave(ICPPASTCompositeTypeSpecifier.ICPPASTBaseSpecifier baseSpecifier)
Description copied from interface: `ICPPASTVisitor`
Visits a base class specifier of a composite type.

Specified by:
  `leave` in interface `ICPPASTVisitor`
Overrides:
  `leave` in class `ASTVisitor`
Returns:
  `ASTVisitor.PROCESS_CONTINUE` or `ASTVisitor.PROCESS_ABORT`

### leave

public int leave(ICPPASTNamespaceDefinition namespaceDefinition)
Description copied from interface: `ICPPASTVisitor`
Visits a namespace definition.

Specified by:
  `leave` in interface `ICPPASTVisitor`
Overrides:
  `leave` in class `ASTVisitor`
Returns:
  `ASTVisitor.PROCESS_CONTINUE` or `ASTVisitor.PROCESS_ABORT`

### leave

public int leave(ICPPASTTemplateParameter templateParameter)
Description copied from interface: `ICPPASTVisitor`
Visits a template parameter.

Specified by:
  `leave` in interface `ICPPASTVisitor`
Overrides:
  `leave` in class `ASTVisitor`
Returns:
  `ASTVisitor.PROCESS_CONTINUE` or `ASTVisitor.PROCESS_ABORT`

### leave

public int leave(ICPPASTCapture capture)

Overrides:
  `leave` in class `ASTVisitor`

### leave

public int leave(IASTArrayModifier arrayModifier)

Overrides:
  `leave` in class `ASTVisitor`

### leave

public int leave(IASTPointerOperator ptrOperator)

Overrides:
  `leave` in class `ASTVisitor`

### leave

public int leave(IASTDeclaration declaration)

Overrides:
  `leave` in class `ASTVisitor`

### leave

public int leave(IASTDeclarator declarator)

Overrides:
  `leave` in class `ASTVisitor`

### leave

public int leave(IASTDeclSpecifier declSpec)

Overrides:
  `leave` in class `ASTVisitor`

### leave

public int leave(IASTEnumerationSpecifier.IASTEnumerator enumerator)

Overrides:
  `leave` in class `ASTVisitor`

### leave

public int leave(IASTExpression expression)

Overrides:
  `leave` in class `ASTVisitor`

### leave

public int leave(IASTInitializer initializer)

Overrides:
  `leave` in class `ASTVisitor`

### leave

public int leave(IASTName name)

Overrides:
  `leave` in class `ASTVisitor`

### leave

public int leave(IASTParameterDeclaration parameterDeclaration)

Overrides:
  `leave` in class `ASTVisitor`

### leave

public int leave(IASTProblem problem)

Overrides:
  `leave` in class `ASTVisitor`

### leave

public int leave(IASTStatement statement)

Overrides:
  `leave` in class `ASTVisitor`

### leave

public int leave(IASTTranslationUnit tu)

Overrides:
  `leave` in class `ASTVisitor`

### leave

public int leave(IASTTypeId typeId)

Overrides:
  `leave` in class `ASTVisitor`