JavaObjectpublic class JavaObject extends Object This class is container for Java Object information. It contains all object data. |
Fields Summary |
---|
public final int | addressaddress of the java object | final int | class_idunique id of class of the java object | public final int | sizesize of the java object | public final int | object_type | private int | root_distance | final int | _stack_idthese fields are used only for stacks | final HashMap | _stack_offsets | final int[] | _references_addressesaddresses of the objects which are referenced by this object | private Collection | _references | private Collection | _referees |
Constructors Summary |
---|
JavaObject(int p_address, int p_class_id, int p_size, int[] references, int p_obj_type)
this(p_address, p_class_id, p_size, references, p_obj_type, null, -1);
| JavaObject(int p_address, int p_class_id, int p_size, int[] references, int p_obj_tp, HashMap offsets, int stack_id)
address = p_address;
class_id = p_class_id;
size = p_size;
object_type = p_obj_tp;
_references_addresses = references;
_stack_offsets = offsets;
_stack_id = stack_id;
|
Methods Summary |
---|
public void | add_referee(com.sun.cldchi.tools.memoryprofiler.data.JavaObject referee)
_referees.add(referee);
| public void | add_reference(com.sun.cldchi.tools.memoryprofiler.data.JavaObject reference)
_references.add(reference);
| public boolean | alive()return true, if there is a chain of linked objects started from
a root object and finished in this objectreturn root_distance != -1;
| public int | getRootDistance()return minimal size of a chain of linked objects started from
a root object and finished in this object
return root_distance;
| public java.lang.Object[] | get_referees()return the array of objects which are reference this object
return _referees.toArray();
| public java.lang.Object[] | get_references()return the array of objects which are referenced by this object
return _references.toArray();
| void | setRootDistance(int dist)set the minimal size of a chain of linked objects started from
a root object and finished in this object
root_distance = dist;
| public java.lang.String | toString()
return /*Integer.toString(root_distance) + */"0x" + Integer.toHexString(address);
|
|