- java.lang.Object
-
- com.ibm.j9ddr.vm29.pointer.helper.J9ObjectHelper
-
- Direct Known Subclasses:
J9IndexableObjectHelper
public class J9ObjectHelper extends Object
-
-
Field Summary
Fields Modifier and Type Field Description static booleancompressObjectReferencesstatic booleanmixedReferenceMode
-
Constructor Summary
Constructors Constructor Description J9ObjectHelper()
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static com.ibm.j9ddr.vm29.pointer.generated.J9ClassPointerclazz(com.ibm.j9ddr.vm29.pointer.generated.J9ObjectPointer objPointer)static U32flags(com.ibm.j9ddr.vm29.pointer.generated.J9ObjectPointer objPointer)static booleangetBooleanField(com.ibm.j9ddr.vm29.pointer.generated.J9ObjectPointer objPointer, J9ObjectFieldOffset offset)Returns an boolean field from the object or its super classes.static bytegetByteField(com.ibm.j9ddr.vm29.pointer.generated.J9ObjectPointer objPointer, J9ObjectFieldOffset offset)Returns an byte field from the object or its super classes.static bytegetByteFromArrayByIndex(Object obj, int index)static chargetCharField(com.ibm.j9ddr.vm29.pointer.generated.J9ObjectPointer objPointer, J9ObjectFieldOffset offset)Returns a char field from the object or its super classes.static StringgetClassName(com.ibm.j9ddr.vm29.pointer.generated.J9ObjectPointer objPointer)Return the name of this J9Object's classstatic doublegetDoubleField(com.ibm.j9ddr.vm29.pointer.generated.J9ObjectPointer objPointer, J9ObjectFieldOffset offset)Returns a double field from the object or its super classes.static J9ObjectFieldOffsetgetFieldOffset(com.ibm.j9ddr.vm29.pointer.generated.J9ObjectPointer objPointer, String name, String signature)static floatgetFloatField(com.ibm.j9ddr.vm29.pointer.generated.J9ObjectPointer objPointer, J9ObjectFieldOffset offset)Returns a float field from the object or its super classes.static intgetIntField(com.ibm.j9ddr.vm29.pointer.generated.J9ObjectPointer objPointer, J9ObjectFieldOffset offset)Returns an int field from the object or its super classes.static StringgetJavaName(com.ibm.j9ddr.vm29.pointer.generated.J9ObjectPointer objPointer)static longgetLongField(com.ibm.j9ddr.vm29.pointer.generated.J9ObjectPointer objPointer, J9ObjectFieldOffset offset)Returns an long field from the object or its super classes.static com.ibm.j9ddr.vm29.pointer.generated.J9ObjectPointergetObjectField(com.ibm.j9ddr.vm29.pointer.generated.J9ObjectPointer objPointer, J9ObjectFieldOffset offset)Returns an Object field from the object or its super classes.static shortgetShortField(com.ibm.j9ddr.vm29.pointer.generated.J9ObjectPointer objPointer, J9ObjectFieldOffset offset)Returns a short field from the object or its super classes.static StringgetStringField(com.ibm.j9ddr.vm29.pointer.generated.J9ObjectPointer objPointer, J9ObjectFieldOffset offset)Returns a String field from the object or its super classes.static longheaderSize()static booleanisIndexable(com.ibm.j9ddr.vm29.pointer.generated.J9ObjectPointer objPointer)Returns TRUE if an object is indexable, FALSE otherwise.static UDATAmonitor(com.ibm.j9ddr.vm29.pointer.generated.J9ObjectPointer objPointer)static UDATArawClazz(com.ibm.j9ddr.vm29.pointer.generated.J9ObjectPointer objPointer)static voidreportClassCacheStats()static StringstringValue(com.ibm.j9ddr.vm29.pointer.generated.J9ObjectPointer objPointer)
-
-
-
Method Detail
-
isIndexable
public static boolean isIndexable(com.ibm.j9ddr.vm29.pointer.generated.J9ObjectPointer objPointer) throws CorruptDataExceptionReturns TRUE if an object is indexable, FALSE otherwise.- Parameters:
objectPtr- Pointer to an object- Returns:
- TRUE if an object is indexable, FALSE otherwise
- Throws:
CorruptDataException
-
flags
public static U32 flags(com.ibm.j9ddr.vm29.pointer.generated.J9ObjectPointer objPointer) throws CorruptDataException
- Throws:
CorruptDataException
-
headerSize
public static long headerSize()
-
rawClazz
public static UDATA rawClazz(com.ibm.j9ddr.vm29.pointer.generated.J9ObjectPointer objPointer) throws CorruptDataException
- Throws:
CorruptDataException
-
clazz
public static com.ibm.j9ddr.vm29.pointer.generated.J9ClassPointer clazz(com.ibm.j9ddr.vm29.pointer.generated.J9ObjectPointer objPointer) throws CorruptDataException- Throws:
CorruptDataException
-
monitor
public static UDATA monitor(com.ibm.j9ddr.vm29.pointer.generated.J9ObjectPointer objPointer) throws CorruptDataException
- Throws:
CorruptDataException
-
getClassName
public static String getClassName(com.ibm.j9ddr.vm29.pointer.generated.J9ObjectPointer objPointer) throws CorruptDataException
Return the name of this J9Object's class- Throws:
CorruptDataException
-
getJavaName
public static String getJavaName(com.ibm.j9ddr.vm29.pointer.generated.J9ObjectPointer objPointer) throws CorruptDataException
- Throws:
CorruptDataException
-
stringValue
public static String stringValue(com.ibm.j9ddr.vm29.pointer.generated.J9ObjectPointer objPointer) throws CorruptDataException
- Throws:
CorruptDataException
-
getStringField
public static String getStringField(com.ibm.j9ddr.vm29.pointer.generated.J9ObjectPointer objPointer, J9ObjectFieldOffset offset) throws CorruptDataException
Returns a String field from the object or its super classes. The field may be a static field or an instance field.- Parameters:
offset- the offset of the field to return- Returns:
- the String value of the field
- Throws:
CorruptDataException- if there is a problem reading the underlying data from the core file
-
getIntField
public static int getIntField(com.ibm.j9ddr.vm29.pointer.generated.J9ObjectPointer objPointer, J9ObjectFieldOffset offset) throws CorruptDataExceptionReturns an int field from the object or its super classes. The field may be a static field or an instance field.- Parameters:
offset- the offset of the field to return- Returns:
- the int value of the field
- Throws:
CorruptDataException- if there is a problem reading the underlying data from the core file
-
getShortField
public static short getShortField(com.ibm.j9ddr.vm29.pointer.generated.J9ObjectPointer objPointer, J9ObjectFieldOffset offset) throws CorruptDataExceptionReturns a short field from the object or its super classes. The field may be a static field or an instance field.- Parameters:
offset- the offset of the field to return- Returns:
- the short value of the field
- Throws:
CorruptDataException- if there is a problem reading the underlying data from the core file
-
getFloatField
public static float getFloatField(com.ibm.j9ddr.vm29.pointer.generated.J9ObjectPointer objPointer, J9ObjectFieldOffset offset) throws CorruptDataExceptionReturns a float field from the object or its super classes. The field may be a static field or an instance field.- Parameters:
offset- the offset of the field to return- Returns:
- the float value of the field
- Throws:
CorruptDataException- if there is a problem reading the underlying data from the core file
-
getDoubleField
public static double getDoubleField(com.ibm.j9ddr.vm29.pointer.generated.J9ObjectPointer objPointer, J9ObjectFieldOffset offset) throws CorruptDataExceptionReturns a double field from the object or its super classes. The field may be a static field or an instance field.- Parameters:
offset- the offset of the field to return- Returns:
- the float value of the field
- Throws:
CorruptDataException- if there is a problem reading the underlying data from the core file
-
getCharField
public static char getCharField(com.ibm.j9ddr.vm29.pointer.generated.J9ObjectPointer objPointer, J9ObjectFieldOffset offset) throws CorruptDataExceptionReturns a char field from the object or its super classes. The field may be a static field or an instance field.- Parameters:
offset- the offset of the field to return- Returns:
- the char value of the field
- Throws:
CorruptDataException- if there is a problem reading the underlying data from the core file
-
getByteField
public static byte getByteField(com.ibm.j9ddr.vm29.pointer.generated.J9ObjectPointer objPointer, J9ObjectFieldOffset offset) throws CorruptDataExceptionReturns an byte field from the object or its super classes. The field may be a static field or an instance field.- Parameters:
offset- the offset of the field to return- Returns:
- the byte value of the field
- Throws:
CorruptDataException- if there is a problem reading the underlying data from the core file
-
getBooleanField
public static boolean getBooleanField(com.ibm.j9ddr.vm29.pointer.generated.J9ObjectPointer objPointer, J9ObjectFieldOffset offset) throws CorruptDataExceptionReturns an boolean field from the object or its super classes. The field may be a static field or an instance field.- Parameters:
offset- the offset of the field to return- Returns:
- the boolean value of the field
- Throws:
CorruptDataException- if there is a problem reading the underlying data from the core file
-
getLongField
public static long getLongField(com.ibm.j9ddr.vm29.pointer.generated.J9ObjectPointer objPointer, J9ObjectFieldOffset offset) throws CorruptDataExceptionReturns an long field from the object or its super classes. The field may be a static field or an instance field.- Parameters:
offset- the offset of the field to return- Returns:
- the long value of the field
- Throws:
CorruptDataException- if there is a problem reading the underlying data from the core file
-
getObjectField
public static com.ibm.j9ddr.vm29.pointer.generated.J9ObjectPointer getObjectField(com.ibm.j9ddr.vm29.pointer.generated.J9ObjectPointer objPointer, J9ObjectFieldOffset offset) throws CorruptDataExceptionReturns an Object field from the object or its super classes. The field may be a static field or an instance field.- Parameters:
offset- the offset of the field to return- Returns:
- the J9Object value of the field
- Throws:
CorruptDataException- if there is a problem reading the underlying data from the core file
-
getFieldOffset
public static J9ObjectFieldOffset getFieldOffset(com.ibm.j9ddr.vm29.pointer.generated.J9ObjectPointer objPointer, String name, String signature) throws CorruptDataException
- Throws:
CorruptDataException
-
getByteFromArrayByIndex
public static byte getByteFromArrayByIndex(Object obj, int index)
-
reportClassCacheStats
public static void reportClassCacheStats()
-
-