|
Extension SDK 10.1.2 | ||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object oracle.ide.util.Pair
Encapsulates a Pair of objects.
Note: The toString() method returns the toString() of
the first object. This allows for example to easily attach
data to a JList object by passing a Pair("Label", myObject).
Field Summary | |
java.lang.Object |
first
|
java.lang.Object |
second
|
Constructor Summary | |
Pair()
Default constructor |
|
Pair(java.lang.Object firstObj,
java.lang.Object secondObj)
Default constructor |
|
Pair(Pair pair)
Cloning Constructor |
Method Summary | |
int |
compareTo(java.lang.Object o)
implements Comparable on the first element only. |
boolean |
equals(java.lang.Object obj)
|
java.lang.Object |
getFirst()
|
java.lang.Object |
getSecond()
|
int |
hashCode()
|
void |
setFirst(java.lang.Object firstObj)
|
void |
setSecond(java.lang.Object secondObj)
|
java.lang.String |
toString()
|
Methods inherited from class java.lang.Object |
clone, finalize, getClass, notify, notifyAll, wait, wait, wait |
Field Detail |
public java.lang.Object first
public java.lang.Object second
Constructor Detail |
public Pair()
public Pair(java.lang.Object firstObj, java.lang.Object secondObj)
public Pair(Pair pair)
Method Detail |
public void setFirst(java.lang.Object firstObj)
public java.lang.Object getFirst()
public void setSecond(java.lang.Object secondObj)
public java.lang.Object getSecond()
public boolean equals(java.lang.Object obj)
public int hashCode()
public java.lang.String toString()
public int compareTo(java.lang.Object o)
compareTo
in interface java.lang.Comparable
|
Extension SDK | ||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
Copyright © 1997, 2004, Oracle. All rights reserved.