public class SimpleRichFeatureRelationship extends AbstractChangeable implements RichFeatureRelationship
RANK
Modifier | Constructor and Description |
---|---|
protected |
SimpleRichFeatureRelationship() |
|
SimpleRichFeatureRelationship(RichFeature object,
RichFeature subject,
ComparableTerm term,
int rank)
Creates a new instance of SimpleRichFeatureRelationship.
|
Modifier and Type | Method and Description |
---|---|
int |
compareTo(Object o)
Relations are compared first by rank, then object, subject, then finally term.
|
boolean |
equals(Object obj)
Relations are equal if their objects, subjects and terms are equal.
|
static ComparableTerm |
getContainsTerm()
Gets the default CONTAINS term used for defining the relationship between features.
|
Integer |
getId()
Gets the Hibernate ID.
|
RichFeature |
getObject()
Returns the object of this relationship (ie. the feature which
this relationship starts from).
|
int |
getRank()
Gets the rank of this relationship.
|
RichFeature |
getSubject()
Gets the feature that this relationship refers to.
|
ComparableTerm |
getTerm()
Gets the term that describes this relationship.
|
int |
hashCode() |
void |
setId(Integer id)
Sets the Hibernate ID.
|
void |
setRank(int rank)
Sets the rank of this relationship.
|
String |
toString()
Form: "(#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 SimpleRichFeatureRelationship(RichFeature object, RichFeature subject, ComparableTerm term, int rank)
subject
- The subject RichFeature.term
- The relationship term.rank
- the rank of the relationship.protected SimpleRichFeatureRelationship()
public static ComparableTerm getContainsTerm()
public void setRank(int rank) throws ChangeVetoException
setRank
in interface RichFeatureRelationship
rank
- Value of property rank.ChangeVetoException
- if the rank is untasty.public int getRank()
getRank
in interface RichFeatureRelationship
public RichFeature getObject()
getObject
in interface RichFeatureRelationship
public RichFeature getSubject()
getSubject
in interface RichFeatureRelationship
public ComparableTerm getTerm()
getTerm
in interface RichFeatureRelationship
public int compareTo(Object o)
compareTo
in interface Comparable
public boolean equals(Object obj)
public Integer getId()
Copyright © 2014 BioJava. All rights reserved.