public class ObjectReference extends java.lang.Object implements IStringRepresentation, IObjectFilter<java.lang.Object>
Modifier and Type | Field and Description |
---|---|
static ObjectReference |
NULL_REFERENCE
The object reference for null.
|
Modifier and Type | Method and Description |
---|---|
java.lang.String |
asString()
Returns the string representation of the implementing object.
|
static ObjectReference |
create(java.lang.Object object)
Returns an object reference for the given object.
|
boolean |
equals(java.lang.Object object) |
protected java.lang.String |
getReferenceString() |
int |
hashCode() |
boolean |
matches(java.lang.Object object)
Returns true if the given object has the same reference representation as this object reference.
|
java.lang.String |
toString() |
public static final ObjectReference NULL_REFERENCE
public static ObjectReference create(java.lang.Object object)
object
- The object to create the reference for (may be null).public java.lang.String asString()
IStringRepresentation
asString
in interface IStringRepresentation
public boolean matches(java.lang.Object object)
matches
in interface IObjectFilter<java.lang.Object>
object
- Any object or nullpublic int hashCode()
hashCode
in class java.lang.Object
public boolean equals(java.lang.Object object)
equals
in class java.lang.Object
public java.lang.String toString()
toString
in class java.lang.Object
protected java.lang.String getReferenceString()