public final class JMod extends Object
Modifier and Type | Field and Description |
---|---|
static int |
ABSTRACT
The
abstract modifier. |
static int |
DEFAULT
The
default modifier found in Java 8 and later. |
static int |
FINAL
The
final modifier. |
static int |
NATIVE
The
native modifier. |
static int |
PRIVATE
The
private modifier. |
static int |
PROTECTED
The
protected modifier. |
static int |
PUBLIC
The
public modifier. |
static int |
STATIC
The
static modifier. |
static int |
STRICTFP
The
strictfp modifier. |
static int |
SYNCHRONIZED
The
synchronized modifier. |
static int |
TRANSIENT
The
transient modifier. |
static int |
VOLATILE
The
volatile modifier. |
Constructor and Description |
---|
JMod() |
Modifier and Type | Method and Description |
---|---|
static boolean |
allAreClear(int set,
int test)
Test to see if all modifiers in the given set are absent in the test value.
|
static boolean |
allAreSet(int set,
int test)
Test to see if all modifiers in the given set are present in the test value.
|
static boolean |
anyAreClear(int set,
int test)
Test to see if any of the modifiers in the given set are absent in the test value.
|
static boolean |
anyAreSet(int set,
int test)
Test to see if any of the modifiers in the given set are present in the test value.
|
static int |
of(Element element)
Returns an integer which results in the appropriate modifier based on the element.
|
static boolean |
oneIsSet(int set,
int test)
Test to see if exactly one modifier of the given set is present in the test value.
|
public static final int ABSTRACT
abstract
modifier.public static final int FINAL
final
modifier.public static final int NATIVE
native
modifier.public static final int PRIVATE
private
modifier.public static final int PROTECTED
protected
modifier.public static final int PUBLIC
public
modifier.public static final int STATIC
static
modifier.public static final int STRICTFP
strictfp
modifier.public static final int SYNCHRONIZED
synchronized
modifier.public static final int TRANSIENT
transient
modifier.public static final int VOLATILE
volatile
modifier.public static final int DEFAULT
default
modifier found in Java 8 and later.public static boolean oneIsSet(int set, int test)
set
- the set of modifiers to test againsttest
- the modifier set to testtrue
if exactly one of set
is present in test
, false
otherwisepublic static boolean allAreSet(int set, int test)
set
- the set of modifiers to test againsttest
- the modifier set to testtrue
if all the modifiers in set
are present in test
, false
otherwisepublic static boolean allAreClear(int set, int test)
set
- the set of modifiers to test againsttest
- the modifier set to testtrue
if all the modifiers in set
are absent in test
, false
otherwisepublic static boolean anyAreSet(int set, int test)
set
- the set of modifiers to test againsttest
- the modifier set to testtrue
if any of the modifiers in set
are present in test
, false
otherwisepublic static boolean anyAreClear(int set, int test)
set
- the set of modifiers to test againsttest
- the modifier set to testtrue
if any of the modifiers in set
are absent in test
, false
otherwisepublic static int of(Element element)
element
- the element to check the modifiers onCopyright © 2019 JBoss by Red Hat. All rights reserved.