net.sourceforge.pmd.lang.java.ast
Class AbstractJavaNode

java.lang.Object
  extended by net.sourceforge.pmd.lang.ast.AbstractNode
      extended by net.sourceforge.pmd.lang.java.ast.AbstractJavaNode
All Implemented Interfaces:
Node, JavaNode, ScopedNode
Direct Known Subclasses:
AbstractJavaAccessNode, AbstractJavaTypeNode, ASTAnnotation, ASTAnnotationTypeBody, ASTAnnotationTypeMemberDeclaration, ASTArgumentList, ASTArguments, ASTArrayDimsAndInits, ASTArrayInitializer, ASTAssertStatement, ASTAssignmentOperator, ASTBlock, ASTBlockStatement, ASTBreakStatement, ASTCatchStatement, ASTClassOrInterfaceBody, ASTClassOrInterfaceBodyDeclaration, ASTContinueStatement, ASTDefaultValue, ASTDoStatement, ASTEmptyStatement, ASTEnumBody, ASTEnumConstant, ASTExplicitConstructorInvocation, ASTExtendsList, ASTFinallyStatement, ASTForInit, ASTFormalParameters, ASTForStatement, ASTForUpdate, ASTIfStatement, ASTImplementsList, ASTInitializer, ASTLabeledStatement, ASTMemberSelector, ASTMemberValue, ASTMemberValueArrayInitializer, ASTMemberValuePair, ASTMemberValuePairs, ASTMethodDeclarator, ASTMethodReference, ASTNameList, ASTPackageDeclaration, ASTPrimarySuffix, ASTResources, ASTResourceSpecification, ASTResultType, ASTReturnStatement, ASTRSIGNEDSHIFT, ASTRUNSIGNEDSHIFT, ASTStatement, ASTStatementExpressionList, ASTSwitchLabel, ASTSwitchStatement, ASTSynchronizedStatement, ASTThrowStatement, ASTTryStatement, ASTTypeArgument, ASTTypeArguments, ASTTypeBound, ASTTypeParameter, ASTTypeParameters, ASTVariableInitializer, ASTWhileStatement, ASTWildcardBounds, DummyJavaNode

public abstract class AbstractJavaNode
extends AbstractNode
implements JavaNode


Field Summary
protected  JavaParser parser
           
 
Fields inherited from class net.sourceforge.pmd.lang.ast.AbstractNode
beginColumn, beginLine, childIndex, children, endColumn, endLine, id, parent
 
Constructor Summary
AbstractJavaNode(int id)
           
AbstractJavaNode(JavaParser parser, int id)
           
 
Method Summary
 Object childrenAccept(JavaParserVisitor visitor, Object data)
          Accept the visitor.
 Comment comment()
           
 void comment(Comment theComment)
           
 Scope getScope()
           
 Object jjtAccept(JavaParserVisitor visitor, Object data)
          Accept the visitor.
 void jjtClose()
          This method is called after all the child nodes have been added.
 void jjtOpen()
          This method is called after the node has been made the current node.
 void setScope(Scope scope)
           
 String toString()
          Subclasses should implement this method to return a name usable with XPathRule for evaluating Element Names.
 
Methods inherited from class net.sourceforge.pmd.lang.ast.AbstractNode
appendElement, findChildNodesWithXPath, findChildrenOfType, findDescendantsOfType, findDescendantsOfType, getAsDocument, getBeginColumn, getBeginLine, getDataFlowNode, getEndColumn, getEndLine, getFirstChildOfType, getFirstDescendantOfType, getFirstParentOfType, getImage, getNthParent, getParentsOfType, getUserData, hasDecendantOfAnyType, hasDescendantMatchingXPath, hasDescendantOfType, hasImageEqualTo, isFindBoundary, isSingleLine, jjtAddChild, jjtGetChild, jjtGetChildIndex, jjtGetId, jjtGetNumChildren, jjtGetParent, jjtSetChildIndex, jjtSetParent, setDataFlowNode, setImage, setUserData, testingOnly__setBeginColumn, testingOnly__setBeginLine, testingOnly__setEndColumn, testingOnly__setEndLine
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 
Methods inherited from interface net.sourceforge.pmd.lang.ast.Node
findChildNodesWithXPath, findChildrenOfType, findDescendantsOfType, findDescendantsOfType, getAsDocument, getBeginColumn, getBeginLine, getDataFlowNode, getEndColumn, getEndLine, getFirstChildOfType, getFirstDescendantOfType, getFirstParentOfType, getImage, getNthParent, getParentsOfType, getUserData, hasDescendantMatchingXPath, hasDescendantOfType, hasImageEqualTo, isFindBoundary, jjtAddChild, jjtGetChild, jjtGetChildIndex, jjtGetId, jjtGetNumChildren, jjtGetParent, jjtSetChildIndex, jjtSetParent, setDataFlowNode, setImage, setUserData
 

Field Detail

parser

protected JavaParser parser
Constructor Detail

AbstractJavaNode

public AbstractJavaNode(int id)

AbstractJavaNode

public AbstractJavaNode(JavaParser parser,
                        int id)
Method Detail

jjtOpen

public void jjtOpen()
Description copied from interface: Node
This method is called after the node has been made the current node. It indicates that child nodes can now be added to it.

Specified by:
jjtOpen in interface Node
Overrides:
jjtOpen in class AbstractNode

jjtClose

public void jjtClose()
Description copied from interface: Node
This method is called after all the child nodes have been added.

Specified by:
jjtClose in interface Node
Overrides:
jjtClose in class AbstractNode

jjtAccept

public Object jjtAccept(JavaParserVisitor visitor,
                        Object data)
Accept the visitor. *

Specified by:
jjtAccept in interface JavaNode

childrenAccept

public Object childrenAccept(JavaParserVisitor visitor,
                             Object data)
Accept the visitor. *

Specified by:
childrenAccept in interface JavaNode

getScope

public Scope getScope()
Specified by:
getScope in interface JavaNode
Specified by:
getScope in interface ScopedNode

setScope

public void setScope(Scope scope)
Specified by:
setScope in interface JavaNode

comment

public void comment(Comment theComment)

comment

public Comment comment()

toString

public String toString()
Description copied from class: AbstractNode
Subclasses should implement this method to return a name usable with XPathRule for evaluating Element Names.

Specified by:
toString in class AbstractNode


Copyright © 2002–2015 InfoEther. All rights reserved.