Class J9ConstantHelper
java.lang.Object
com.ibm.j9ddr.vm29.j9.J9ConstantHelper
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionstatic boolean
getBoolean
(Class<?> clazz, String name, boolean defaultValue) Using reflection, read the value of a public static final boolean field from the given class or, if the field is not present, return the default value provided.static int
Using reflection, read the value of a public static final int field from the given class or, if the field is not present, return the default value provided.static long
Using reflection, read the value of a public static final long field from the given class or, if the field is not present, return the default value provided.
-
Constructor Details
-
J9ConstantHelper
public J9ConstantHelper()
-
-
Method Details
-
getLong
Using reflection, read the value of a public static final long field from the given class or, if the field is not present, return the default value provided.- Parameters:
clazz
- the class which owns the field of interestname
- the name of the fielddefaultValue
- the value to be returned if the field is not present- Returns:
- the value of the field, or the default value
-
getBoolean
Using reflection, read the value of a public static final boolean field from the given class or, if the field is not present, return the default value provided.- Parameters:
clazz
- the class which owns the field of interestname
- the name of the fielddefaultValue
- the value to be returned if the field is not present- Returns:
- the value of the boolean field, or the default value
-
getInt
Using reflection, read the value of a public static final int field from the given class or, if the field is not present, return the default value provided.- Parameters:
clazz
- the class which owns the field of interestname
- the name of the fielddefaultValue
- the value to be returned if the field is not present- Returns:
- the value of the field, or the default value
-