public class SimpleRankedCrossRef extends AbstractChangeable implements RankedCrossRef
RANK| Modifier | Constructor and Description |
|---|---|
protected |
SimpleRankedCrossRef() |
|
SimpleRankedCrossRef(CrossRef crossref,
int rank)
Constructs a new crossref with a rank.
|
| Modifier and Type | Method and Description |
|---|---|
int |
compareTo(java.lang.Object o)
Ranked cross references are sorted first by rank, then by cross reference.
|
boolean |
equals(java.lang.Object obj)
Ranked cross references are the same if they have the same rank and
refer to the same cross reference (cross references are equal).
|
CrossRef |
getCrossRef()
Return the cross reference associated with this object.
|
int |
getRank()
Return the rank associated with the cross reference.
|
int |
hashCode() |
void |
setRank(int rank)
Set the rank associated with the cross reference.
|
java.lang.String |
toString()
Form: "(#rank) crossref"
|
addChangeListener, addChangeListener, generateChangeSupport, getChangeSupport, hasListeners, hasListeners, isUnchanging, removeChangeListener, removeChangeListenerclone, finalize, getClass, notify, notifyAll, wait, wait, waitaddChangeListener, addChangeListener, isUnchanging, removeChangeListener, removeChangeListenerpublic SimpleRankedCrossRef(CrossRef crossref, int rank)
crossref - the crossref to rank. Must not be null.rank - the rank to give it.protected SimpleRankedCrossRef()
public CrossRef getCrossRef()
getCrossRef in interface RankedCrossRefpublic void setRank(int rank)
throws ChangeVetoException
setRank in interface RankedCrossRefrank - the rank to use.ChangeVetoException - if the new rank is unacceptable.public int getRank()
getRank in interface RankedCrossRefpublic boolean equals(java.lang.Object obj)
equals in class java.lang.Objectpublic int compareTo(java.lang.Object o)
compareTo in interface java.lang.Comparablepublic int hashCode()
hashCode in class java.lang.Objectpublic java.lang.String toString()
toString in class java.lang.Object