public class KeyedObject
extends java.lang.Object
implements java.lang.Cloneable, org.jfree.util.PublicCloneable, java.io.Serializable
| Modifier and Type | Field and Description |
|---|---|
private java.lang.Comparable |
key
The key.
|
private java.lang.Object |
object
The object.
|
private static long |
serialVersionUID
For serialization.
|
| Constructor and Description |
|---|
KeyedObject(java.lang.Comparable key,
java.lang.Object object)
Creates a new (key, object) pair.
|
| Modifier and Type | Method and Description |
|---|---|
java.lang.Object |
clone()
Returns a clone of this object.
|
boolean |
equals(java.lang.Object obj)
Tests if this object is equal to another.
|
java.lang.Comparable |
getKey()
Returns the key.
|
java.lang.Object |
getObject()
Returns the object.
|
void |
setObject(java.lang.Object object)
Sets the object.
|
private static final long serialVersionUID
private java.lang.Comparable key
private java.lang.Object object
public KeyedObject(java.lang.Comparable key,
java.lang.Object object)
key - the key.object - the object (null permitted).public java.lang.Comparable getKey()
public java.lang.Object getObject()
null).public void setObject(java.lang.Object object)
object - the object (null permitted).public java.lang.Object clone()
throws java.lang.CloneNotSupportedException
PublicCloneable, otherwise a shallow clone is
made.clone in interface org.jfree.util.PublicCloneableclone in class java.lang.Objectjava.lang.CloneNotSupportedException - if there is a problem cloning.public boolean equals(java.lang.Object obj)
equals in class java.lang.Objectobj - the other object.