|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--javaslam.util.PriorityQueue.QueueElement
An item in a priority queue.
Field Summary | |
Object |
item
The actual item. |
Comparable |
priority
The priority of the item. |
Constructor Summary | |
PriorityQueue.QueueElement(Object item,
Comparable priority)
Constructor. |
Method Summary | |
int |
compareTo(Object o)
Compares this object with the specified object for order. |
boolean |
equals(Object o)
Returns true if two elements are the same, which
is true only when the corresponding items are equal. |
int |
hashCode()
Returns the hash code of this element's item. |
String |
toString()
Returns a string representation of this queue element. |
Methods inherited from class java.lang.Object |
clone, finalize, getClass, notify, notifyAll, wait, wait, wait |
Field Detail |
public Object item
public Comparable priority
Constructor Detail |
public PriorityQueue.QueueElement(Object item, Comparable priority)
Method Detail |
public int compareTo(Object o)
compareTo
in interface Comparable
o
- the Object to be compared.
ClassCastException
- if the specified object's type prevents
it from being compared to this Object.public boolean equals(Object o)
true
if two elements are the same, which
is true only when the corresponding items are equal.
equals
in class Object
o
- the Object to be compared.
true
if two elements are the same.public int hashCode()
hashCode
in class Object
public String toString()
toString
in class Object
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |