|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object com.puppycrawl.tools.checkstyle.api.ScopeUtils
Contains utility methods for working on scope.
Method Summary | |
static Scope |
getScopeFromMods(DetailAST aMods)
Returns the Scope specified by the modifier set. |
static Scope |
getSurroundingScope(DetailAST aAST)
Returns the scope of the surrounding "block". |
static boolean |
inCodeBlock(DetailAST aAST)
Returns whether the scope of a node is restricted to a code block. |
static boolean |
inInterfaceBlock(DetailAST aAST)
Returns whether a node is directly contained within an interface block. |
static boolean |
isLocalVariableDef(DetailAST aAST)
Determines whether a node is a local variable definition. |
static boolean |
isOuterMostType(DetailAST aAST)
Returns whether a node is contained in the outer most type block. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Method Detail |
public static Scope getScopeFromMods(DetailAST aMods)
aMods
- root node of a modifier set
Scope
valuepublic static Scope getSurroundingScope(DetailAST aAST)
aAST
- the node to return the scope for
public static boolean inInterfaceBlock(DetailAST aAST)
aAST
- the node to check if directly contained within an interface
block
boolean
valuepublic static boolean inCodeBlock(DetailAST aAST)
aAST
- the node to check
boolean
valuepublic static boolean isOuterMostType(DetailAST aAST)
aAST
- the node to check
boolean
valuepublic static boolean isLocalVariableDef(DetailAST aAST)
aAST
- the node to check.
|
Back to the Checkstyle Home Page | ||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |