net.sourceforge.pmd.lang.plsql.ast
Class AbstractPLSQLNode

java.lang.Object
  extended by net.sourceforge.pmd.lang.ast.AbstractNode
      extended by net.sourceforge.pmd.lang.plsql.ast.AbstractPLSQLNode
All Implemented Interfaces:
Node, PLSQLNode, ScopedNode
Direct Known Subclasses:
ASTAccessibleByClause, ASTAdditiveExpression, ASTAlterTrigger, ASTAlterTypeSpec, ASTArgument, ASTArgumentList, ASTArguments, ASTAssignment, ASTAttribute, ASTAttributeDeclaration, ASTBlock, ASTBooleanLiteral, ASTCallSpecTail, ASTCaseExpression, ASTCaseStatement, ASTCaseWhenClause, ASTCloseStatement, ASTCollectionDeclaration, ASTCollectionTypeDefinition, ASTCollectionTypeName, ASTComment, ASTCompilationDataType, ASTCompilationDeclarationFragment, ASTCompilationExpression, ASTCompoundTriggerBlock, ASTConditionalAndExpression, ASTConditionalCompilationStatement, ASTConditionalOrExpression, ASTContinueStatement, ASTCursorBody, ASTCursorSpecification, ASTCursorUnit, ASTDatabaseEvent, ASTDatabaseLink, ASTDatatype, ASTDatatypeDeclaration, ASTDateTimeLiteral, ASTDDLCommand, ASTDDLEvent, ASTDeclarativeSection, ASTDeclarativeUnit, ASTDirectory, ASTElseClause, ASTElsifClause, ASTEmbeddedSqlStatement, ASTEqualityExpression, ASTEqualsOldIDNewID, ASTExceptionDeclaration, ASTExceptionHandler, ASTExitStatement, ASTExpression, ASTFetchStatement, ASTFieldDeclaration, ASTForAllIndex, ASTForAllStatement, ASTForIndex, ASTFormalParameter, ASTFormalParameters, ASTForStatement, ASTGlobal, ASTGotoStatement, ASTID, ASTIfStatement, ASTInlinePragma, ASTInput, ASTJavaInterfaceClass, ASTKEYWORD_RESERVED, ASTKEYWORD_UNRESERVED, ASTLabel, ASTLabelledStatement, ASTLikeExpression, ASTLiteral, ASTLoopStatement, ASTMethodDeclaration, ASTMethodDeclarator, ASTMultiplicativeExpression, ASTMultiSetCondition, ASTName, ASTNonDMLEvent, ASTNonDMLTrigger, ASTNullLiteral, ASTNumericLiteral, ASTObjectDeclaration, ASTObjectExpression, ASTObjectNameDeclaration, ASTOpenStatement, ASTPackageBody, ASTPackageSpecification, ASTParallelClause, ASTPipelineStatement, ASTPragma, ASTPragmaClause, ASTPrimaryExpression, ASTPrimaryPrefix, ASTPrimarySuffix, ASTProgramUnit, ASTQualifiedID, ASTQualifiedName, ASTRaiseStatement, ASTRead2NextOccurrence, ASTReadPastNextOccurrence, ASTRelationalExpression, ASTReturnStatement, ASTScalarDataTypeName, ASTSkip2NextOccurrence, ASTSkip2NextTerminator, ASTSkip2NextTokenOccurrence, ASTSkipPastNextOccurrence, ASTSkipPastNextTokenOccurrence, ASTSqlPlusCommand, ASTSqlStatement, ASTStatement, ASTStringExpression, ASTStringLiteral, ASTSubTypeDefinition, ASTSynonym, ASTTable, ASTTableColumn, ASTTriggerTimingPointSection, ASTTriggerUnit, ASTTrimExpression, ASTTypeKeyword, ASTTypeMethod, ASTTypeSpecification, ASTUnaryExpression, ASTUnaryExpressionNotPlusMinus, ASTUnlabelledStatement, ASTUnqualifiedID, ASTVariableOrConstantDeclaration, ASTVariableOrConstantDeclarator, ASTVariableOrConstantDeclaratorId, ASTVariableOrConstantInitializer, ASTView, ASTViewColumn, ASTWhileStatement, ASTWrappedObject

public abstract class AbstractPLSQLNode
extends AbstractNode
implements PLSQLNode


Field Summary
protected  PLSQLParser parser
           
protected  Scope scope
           
protected  Object value
           
 
Fields inherited from class net.sourceforge.pmd.lang.ast.AbstractNode
beginColumn, beginLine, childIndex, children, endColumn, endLine, firstToken, id, lastToken, parent
 
Constructor Summary
AbstractPLSQLNode(int i)
           
AbstractPLSQLNode(PLSQLParser p, int i)
           
 
Method Summary
 Object childrenAccept(PLSQLParserVisitor visitor, Object data)
          Accept the visitor.
 void dump(String prefix)
           
 String getCanonicalImage()
          Return node image converted to the normal Oracle form.
static String getCanonicalImage(String image)
          Convert arbitrary String to normal Oracle format, under assumption that the passed image is an Oracle name.
 Scope getScope()
           
 Object jjtAccept(PLSQLParserVisitor visitor, Object data)
          Accept the visitor.
 void jjtClose()
           
 Object jjtGetValue()
           
 void jjtOpen()
           
 void jjtSetValue(Object value)
           
 void setScope(Scope scope)
           
 String toString()
           
 String toString(String prefix)
           
 
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, jjtGetFirstToken, jjtGetId, jjtGetLastToken, jjtGetNumChildren, jjtGetParent, jjtSetChildIndex, jjtSetFirstToken, jjtSetLastToken, 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

value

protected Object value

parser

protected PLSQLParser parser

scope

protected Scope scope
Constructor Detail

AbstractPLSQLNode

public AbstractPLSQLNode(int i)

AbstractPLSQLNode

public AbstractPLSQLNode(PLSQLParser p,
                         int i)
Method Detail

jjtOpen

public void jjtOpen()
Specified by:
jjtOpen in interface Node
Overrides:
jjtOpen in class AbstractNode

jjtClose

public void jjtClose()
Specified by:
jjtClose in interface Node
Overrides:
jjtClose in class AbstractNode

jjtSetValue

public void jjtSetValue(Object value)

jjtGetValue

public Object jjtGetValue()

jjtAccept

public Object jjtAccept(PLSQLParserVisitor visitor,
                        Object data)
Description copied from interface: PLSQLNode
Accept the visitor.

Specified by:
jjtAccept in interface PLSQLNode

childrenAccept

public Object childrenAccept(PLSQLParserVisitor visitor,
                             Object data)
Description copied from interface: PLSQLNode
Accept the visitor.

Specified by:
childrenAccept in interface PLSQLNode

toString

public String toString()
Specified by:
toString in class AbstractNode

toString

public String toString(String prefix)

dump

public void dump(String prefix)

getCanonicalImage

public String getCanonicalImage()
Return node image converted to the normal Oracle form.

Normally this is uppercase, unless the names is quoted ("name").


getCanonicalImage

public static String getCanonicalImage(String image)
Convert arbitrary String to normal Oracle format, under assumption that the passed image is an Oracle name.

This a helper method for PLSQL classes dependent on SimpleNode, that would otherwise have to import PLSQParser.

Parameters:
image -
Returns:

getScope

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

setScope

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


Copyright © 2002-2016 InfoEther. All Rights Reserved.