Package org.eclipse.mat.snapshot.model
Class ObjectReference
- java.lang.Object
-
- org.eclipse.mat.snapshot.model.ObjectReference
-
- All Implemented Interfaces:
Serializable
- Direct Known Subclasses:
NamedReference
public class ObjectReference extends Object implements Serializable
The value of a field if it is an object reference.- See Also:
- Serialized Form
-
-
Constructor Summary
Constructors Constructor Description ObjectReference(ISnapshot snapshot, long address)
Create a reference to an object based on its address but in a form where the object id can be found.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description boolean
equals(Object obj)
IObject
getObject()
Get a detailed view of the objectlong
getObjectAddress()
The actual address of the objectint
getObjectId()
The id of the objectint
hashCode()
String
toString()
A simple view of the object as an address
-
-
-
Constructor Detail
-
ObjectReference
public ObjectReference(ISnapshot snapshot, long address)
Create a reference to an object based on its address but in a form where the object id can be found.- Parameters:
snapshot
-address
-
-
-
Method Detail
-
getObjectAddress
public long getObjectAddress()
The actual address of the object- Returns:
- the address
-
getObjectId
public int getObjectId() throws SnapshotException
The id of the object- Returns:
- the object id
- Throws:
SnapshotException
-
getObject
public IObject getObject() throws SnapshotException
Get a detailed view of the object- Returns:
- the object detail
- Throws:
SnapshotException
-
toString
public String toString()
A simple view of the object as an address
-
-