|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectkoala.dynamicjava.util.TigerUtilities
public class TigerUtilities
Common utilities of DynamicJava for implementing features of 1.5.
| Field Summary | |
|---|---|
static int |
ANNOTATION
|
static int |
BRIDGE
|
static int |
ENUM
|
static int |
SYNTHETIC
|
static int |
VARARGS
|
static float |
VERSION
The version of the java runtime environment that is in use. |
| Constructor Summary | |
|---|---|
TigerUtilities()
|
|
| Method Summary | |
|---|---|
static void |
assertTigerEnabled(String msg)
To be called before a feature of 1.5 is used. |
static boolean |
boxesTo(Class<?> prim,
Class<?> ref)
Returns true iff the given primitive class can be boxed to the given reference class. |
static Class<?> |
correspondingBoxingType(Class<?> primType)
Returns the reference type that corresponds to the given primitive type. |
static Class<?> |
correspondingPrimType(Class<?> refType)
Returns the primitive type that corresponds to the given reference type. |
static boolean |
isBoxingType(Class<?> c)
Returns if the given class is a reference type |
static boolean |
isBridge(Method m)
|
static boolean |
isEnum(Class<?> c)
|
static boolean |
isEnumConstant(Field f)
|
static boolean |
isIntegralType(Class<?> c)
Returns true iff the given class is an integral type This includes both primitive and boxing integral types. Allowed primitives: byte, char, short, int, long Allowed Refrence: Byte, Character, Short, Integer, Long |
static boolean |
isTigerEnabled()
Accessor method for _tigerEnabled. |
static boolean |
isVarArgs(Constructor<?> c)
|
static boolean |
isVarArgs(Method m)
|
static void |
resetVersion()
Resets _tigerEnabled based upon the version of the runtime environment that is being used. |
static void |
setTigerEnabled(boolean enabled)
Allows the features in 1.5 to be enabled or disabled. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
public static final int BRIDGE
public static final int VARARGS
public static final int SYNTHETIC
public static final int ANNOTATION
public static final int ENUM
public static final float VERSION
| Constructor Detail |
|---|
public TigerUtilities()
| Method Detail |
|---|
public static void resetVersion()
public static boolean isTigerEnabled()
public static void setTigerEnabled(boolean enabled)
enabled - - a boolean that specifies whether or not Tiger features are to be enabledpublic static void assertTigerEnabled(String msg)
msg - The error message if 1.5 is not enabledpublic static boolean isVarArgs(Method m)
public static boolean isVarArgs(Constructor<?> c)
public static boolean isBridge(Method m)
public static boolean isEnum(Class<?> c)
public static boolean isEnumConstant(Field f)
public static Class<?> correspondingBoxingType(Class<?> primType)
primType - the primitive type
public static Class<?> correspondingPrimType(Class<?> refType)
refType - the reference type
public static boolean isBoxingType(Class<?> c)
c - the class that may be a reference type
public static boolean isIntegralType(Class<?> c)
c - The class to check
public static boolean boxesTo(Class<?> prim,
Class<?> ref)
prim - - the primitive class being boxedref - - the reference class being boxed to
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||