public class SimpleBioEntryRelationship extends AbstractChangeable implements BioEntryRelationship
RANK
Modifier | Constructor and Description |
---|---|
protected |
SimpleBioEntryRelationship() |
|
SimpleBioEntryRelationship(BioEntry object,
BioEntry subject,
ComparableTerm term,
java.lang.Integer rank)
Creates a new instance of SimpleBioEntryRelationship.
|
Modifier and Type | Method and Description |
---|---|
int |
compareTo(java.lang.Object o)
A relationship is compared first by rank, then object, subject, and term.
|
boolean |
equals(java.lang.Object obj)
Relationships are equal if they share the same rank, object, subject and term.
|
java.lang.Integer |
getId()
Gets the Hibernate ID.
|
BioEntry |
getObject()
Returns the object of this relationship (ie.
|
java.lang.Integer |
getRank()
Returns the rank of this relationship.
|
BioEntry |
getSubject()
Returns the subject of this relationship (ie.
|
ComparableTerm |
getTerm()
Returns the term describing the relationship.
|
int |
hashCode() |
void |
setId(java.lang.Integer id)
Sets the Hibernate ID.
|
void |
setRank(java.lang.Integer rank)
Sets the rank of this relationship.
|
java.lang.String |
toString()
Form is "(#rank) term(object,subject)"
|
addChangeListener, addChangeListener, generateChangeSupport, getChangeSupport, hasListeners, hasListeners, isUnchanging, removeChangeListener, removeChangeListener
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
addChangeListener, addChangeListener, isUnchanging, removeChangeListener, removeChangeListener
public SimpleBioEntryRelationship(BioEntry object, BioEntry subject, ComparableTerm term, java.lang.Integer rank)
rank
- The rank of the relationship.subject
- The subject bioentry.term
- The relationship term.protected SimpleBioEntryRelationship()
public void setRank(java.lang.Integer rank) throws ChangeVetoException
setRank
in interface BioEntryRelationship
rank
- Value of property rank.ChangeVetoException
- if the rank rankles.public java.lang.Integer getRank()
getRank
in interface BioEntryRelationship
public BioEntry getObject()
getObject
in interface BioEntryRelationship
public BioEntry getSubject()
getSubject
in interface BioEntryRelationship
public ComparableTerm getTerm()
getTerm
in interface BioEntryRelationship
public int compareTo(java.lang.Object o)
compareTo
in interface java.lang.Comparable
public boolean equals(java.lang.Object obj)
equals
in class java.lang.Object
public int hashCode()
hashCode
in class java.lang.Object
public java.lang.String toString()
toString
in class java.lang.Object
public java.lang.Integer getId()
public void setId(java.lang.Integer id)
id
- the Hibernate ID, if using Hibernate.