Class ASTModifierNode
- java.lang.Object
-
- net.sourceforge.pmd.lang.ast.impl.AbstractNode<net.sourceforge.pmd.lang.apex.ast.AbstractApexNode<?>,ApexNode<?>>
-
- net.sourceforge.pmd.lang.apex.ast.ASTModifierNode
-
- All Implemented Interfaces:
AccessNode,ApexNode<apex.jorje.semantic.ast.modifier.ModifierNode>,GenericNode<ApexNode<?>>,Node,Reportable
public final class ASTModifierNode extends AbstractNode<net.sourceforge.pmd.lang.apex.ast.AbstractApexNode<?>,ApexNode<?>> implements AccessNode
-
-
Method Summary
All Methods Instance Methods Concrete Methods Deprecated Methods Modifier and Type Method Description protected <P,R>
RacceptApexVisitor(ApexVisitor<? super P,? extends R> visitor, P data)<P,R>
RacceptVisitor(AstVisitor<? super P,? extends R> visitor, P data)protected voidaddChild(net.sourceforge.pmd.lang.apex.ast.AbstractApexNode<?> child, int index)StringgetDefiningType()intgetModifiers()StringgetNamespace()TgetNode()Deprecated.@NonNull ASTApexFilegetRoot()@NonNull TextRegiongetTextRegion()StringgetXPathNodeName()booleanhasDeprecatedTestMethod()Returns true if function has `testmethod` modifierbooleanhasRealLoc()protected voidinsertChild(net.sourceforge.pmd.lang.apex.ast.AbstractApexNode<?> child, int index)booleanisAbstract()booleanisFinal()booleanisGlobal()booleanisInheritedSharing()booleanisOverride()booleanisPrivate()booleanisProtected()booleanisPublic()booleanisStatic()booleanisTest()Returns true if function has `@isTest` annotation or `testmethod` modifierbooleanisTestOrTestSetup()booleanisTransient()booleanisVirtual()booleanisWebService()booleanisWithoutSharing()booleanisWithSharing()protected voidsetRegion(TextRegion region)-
Methods inherited from class net.sourceforge.pmd.lang.ast.impl.AbstractNode
children, firstChild, getChild, getIndexInParent, getNumChildren, getParent, getUserMap, remove, removeChildAtIndex, setChild, setParent, toString
-
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.apex.ast.ApexNode
getApexVersion, jjtAccept
-
Methods inherited from interface net.sourceforge.pmd.lang.ast.impl.GenericNode
ancestors, ancestorsOrSelf, asStream, children, descendants, descendantsOrSelf, getChild, getFirstChild, getLastChild, getNextSibling, getNthParent, getParent, getPreviousSibling
-
Methods inherited from interface net.sourceforge.pmd.lang.ast.Node
acceptVisitor, ancestors, children, compareLocation, descendants, findChildNodesWithXPath, findChildrenOfType, findDescendantsOfType, findDescendantsOfType, firstChild, getAstInfo, getBeginColumn, getBeginLine, getEndColumn, getEndLine, getFirstChildOfType, getFirstDescendantOfType, getFirstParentOfType, getImage, getIndexInParent, getLanguageVersion, getNumChildren, getParentsOfType, getReportLocation, getTextDocument, getTextRegion, getUserMap, getXPathAttributesIterator, getXPathNodeName, hasDescendantOfType, hasImageEqualTo, isFindBoundary
-
-
-
-
Method Detail
-
acceptApexVisitor
protected <P,R> R acceptApexVisitor(ApexVisitor<? super P,? extends R> visitor, P data)
-
getModifiers
public int getModifiers()
- Specified by:
getModifiersin interfaceAccessNode
-
isPublic
public boolean isPublic()
- Specified by:
isPublicin interfaceAccessNode
-
isProtected
public boolean isProtected()
- Specified by:
isProtectedin interfaceAccessNode
-
isPrivate
public boolean isPrivate()
- Specified by:
isPrivatein interfaceAccessNode
-
isAbstract
public boolean isAbstract()
- Specified by:
isAbstractin interfaceAccessNode
-
isStatic
public boolean isStatic()
- Specified by:
isStaticin interfaceAccessNode
-
isFinal
public boolean isFinal()
- Specified by:
isFinalin interfaceAccessNode
-
isTransient
public boolean isTransient()
- Specified by:
isTransientin interfaceAccessNode
-
isTest
public boolean isTest()
Returns true if function has `@isTest` annotation or `testmethod` modifier
-
hasDeprecatedTestMethod
public boolean hasDeprecatedTestMethod()
Returns true if function has `testmethod` modifier
-
isTestOrTestSetup
public boolean isTestOrTestSetup()
-
isWithSharing
public boolean isWithSharing()
-
isWithoutSharing
public boolean isWithoutSharing()
-
isInheritedSharing
public boolean isInheritedSharing()
-
isWebService
public boolean isWebService()
-
isGlobal
public boolean isGlobal()
-
isOverride
public boolean isOverride()
-
isVirtual
public boolean isVirtual()
-
addChild
protected void addChild(net.sourceforge.pmd.lang.apex.ast.AbstractApexNode<?> child, int index)- Overrides:
addChildin classAbstractNode<net.sourceforge.pmd.lang.apex.ast.AbstractApexNode<?>,ApexNode<?>>
-
insertChild
protected void insertChild(net.sourceforge.pmd.lang.apex.ast.AbstractApexNode<?> child, int index)- Overrides:
insertChildin classAbstractNode<net.sourceforge.pmd.lang.apex.ast.AbstractApexNode<?>,ApexNode<?>>
-
acceptVisitor
public final <P,R> R acceptVisitor(AstVisitor<? super P,? extends R> visitor, P data)
- Specified by:
acceptVisitorin interfaceNode
-
getRoot
public @NonNull ASTApexFile getRoot()
-
getTextRegion
public @NonNull TextRegion getTextRegion()
- Specified by:
getTextRegionin interfaceNode
-
getXPathNodeName
public final String getXPathNodeName()
- Specified by:
getXPathNodeNamein interfaceNode
-
setRegion
protected void setRegion(TextRegion region)
-
getNode
@Deprecated @InternalApi public T getNode()
Deprecated.Description copied from interface:ApexNodeGet the underlying AST node.
-
hasRealLoc
public boolean hasRealLoc()
- Specified by:
hasRealLocin interfaceApexNode<T extends apex.jorje.semantic.ast.AstNode>
-
getDefiningType
public String getDefiningType()
- Specified by:
getDefiningTypein interfaceApexNode<T extends apex.jorje.semantic.ast.AstNode>
-
getNamespace
public String getNamespace()
- Specified by:
getNamespacein interfaceApexNode<T extends apex.jorje.semantic.ast.AstNode>
-
-