public final class JavaNodeModifier
extends java.lang.reflect.Modifier
This class can be used to get the access level of a class, method, field...
Modifier and Type | Field and Description |
---|---|
static int |
UNKNOWN
Unknown keyword.
|
Modifier and Type | Method and Description |
---|---|
static boolean |
isAbstract(de.hunsicker.antlr.collections.AST modifiers)
Indicates whether the given modifiers node contains the abstract keyword.
|
static boolean |
isFinal(de.hunsicker.antlr.collections.AST modifiers)
Indicates whether the given modifiers node contains the final keyword.
|
static boolean |
isFriendly(de.hunsicker.antlr.collections.AST modifiers)
Indicates whether the given modifiers node denotes package protected (friendly)
access.
|
static boolean |
isFriendly(int modifiers)
Indicates whether the given modifier denotes package protected (friendly) access.
|
static boolean |
isPrivate(de.hunsicker.antlr.collections.AST modifiers)
Indicates whether the given modifiers node contains the private keyword.
|
static boolean |
isProtected(de.hunsicker.antlr.collections.AST modifiers)
Indicates whether the given modifiers node contains the protected
keyword.
|
static boolean |
isPublic(de.hunsicker.antlr.collections.AST modifiers)
Indicates whether the given modifiers node contains the public keyword.
|
static boolean |
isStatic(de.hunsicker.antlr.collections.AST modifiers)
Indicates whether the given modifiers node contains the static keyword.
|
static boolean |
isSynchronized(de.hunsicker.antlr.collections.AST modifiers)
Indicates whether the given modifiers node contains the synchronized
keyword.
|
static int |
valueOf(de.hunsicker.antlr.collections.AST modifiers)
Returns the modifier mask of the given modifiers node.
|
public static final int UNKNOWN
public static boolean isAbstract(de.hunsicker.antlr.collections.AST modifiers)
modifiers
- MODIFIERS node to check.true
if the given node contains the abstract
keyword.public static boolean isFinal(de.hunsicker.antlr.collections.AST modifiers)
modifiers
- MODIFIERS node to check.true
if the given node contains the final keyword.public static boolean isFriendly(de.hunsicker.antlr.collections.AST modifiers)
modifiers
- true
if the node denotes package protected access.public static boolean isFriendly(int modifiers)
modifiers
- MODIFIERS node to check.true
if the node denotes package protected access.public static boolean isPrivate(de.hunsicker.antlr.collections.AST modifiers)
modifiers
- MODIFIERS node to check.true
if the given node contains the private keyword.public static boolean isProtected(de.hunsicker.antlr.collections.AST modifiers)
modifiers
- MODIFIERS node to check.true
if the given node contains the protected
keyword.public static boolean isPublic(de.hunsicker.antlr.collections.AST modifiers)
modifiers
- MODIFIERS node to check.true
if the given node contains the public keyword.public static boolean isStatic(de.hunsicker.antlr.collections.AST modifiers)
modifiers
- MODIFIERS node to check.true
if the given node contains the static keyword.public static boolean isSynchronized(de.hunsicker.antlr.collections.AST modifiers)
modifiers
- MODIFIERS node to check.true
if the given node contains the synchronized
keyword.public static int valueOf(de.hunsicker.antlr.collections.AST modifiers)
modifiers
- MODIFIERS node or one of the valid nodes representing modifiers
(e.g. LITERAL_public, LITERAL_synchronized etc.).java.lang.IllegalArgumentException
- if modifiers == null
or
modifiers.getType() != JavaTokenTypes.MODIFIERS
Submit a bug or feature.
For further information and documentation, visit the official Jalopy website.
This page generated: March 30 2013