|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
public interface JavaClass
This class represents java.lang.Class instances on the heap.
Method Summary | |
---|---|
long |
getAllInstancesSize()
returns the size of all instances in bytes. |
Instance |
getClassLoader()
returns Instance representing class loader of this class. |
List<Field> |
getFields()
returns List of instance fields of this JavaClass . |
List<Instance> |
getInstances()
computes the list of all Instance of this class. |
int |
getInstancesCount()
gets number of instances of this class. |
int |
getInstanceSize()
returns the size of the Instance in bytes if this JavaClass does
not represent array. |
long |
getJavaClassId()
gets unique (in whole heap) ID of this JavaClass . |
String |
getName()
return human readable name of the class. |
long |
getRetainedSizeByClass()
gets sum of retained sizes of all class instances. |
List<FieldValue> |
getStaticFieldValues()
computes the list of instance field values. |
Collection<JavaClass> |
getSubClasses()
returns all subclasses of this class. |
JavaClass |
getSuperClass()
returns JavaClass representing super class of this class. |
Object |
getValueOfStaticField(String name)
Returns a value object that reflects the specified static field of the class represented by this JavaClass object. |
boolean |
isArray()
returns true if this JavaClass represents array (for example: java.lang.String[]). |
Method Detail |
---|
Object getValueOfStaticField(String name)
JavaClass
object.
The name parameter is a String that specifies the simple name of the desired static field.
name
- the name of the field
null
is returned.
If the field.getType() is Type
object Instance
is returned as field value,
for primitive types its corresponding object wrapper (Boolean, Integer, Float, etc.) is returned.long getAllInstancesSize()
boolean isArray()
true
if this class represents array, false
otherwiseInstance getClassLoader()
Instance
representing class loader of this class.
List<Field> getFields()
JavaClass
.
Field
instance fieldsint getInstanceSize()
Instance
in bytes if this JavaClass does
not represent array. For arrays -1 is returned
Instance
in bytes, for arrays -1 is returned.List<Instance> getInstances()
Instance
of this class.
The instances are ordered according to Instance.getInstanceNumber()
Instance
of instancesint getInstancesCount()
long getRetainedSizeByClass()
long getJavaClassId()
JavaClass
.
JavaClass
String getName()
getName
in interface Type
List<FieldValue> getStaticFieldValues()
FieldValue
instance field values.Collection<JavaClass> getSubClasses()
Collection
of JavaClass
.JavaClass getSuperClass()
JavaClass
representing super class of this class.
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |