|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.biojavax.bio.taxa.SimpleNCBITaxonName
public class SimpleNCBITaxonName
Represents a name class plus name combination for an NCBITaxon object.
Constructor Summary | |
---|---|
protected |
SimpleNCBITaxonName()
|
|
SimpleNCBITaxonName(String nameClass,
String name)
Creates a new taxon name based on the given class and name, both of which cannot be null. |
Method Summary | |
---|---|
int |
compareTo(Object o)
Taxon names are sorted by class first, then name. |
boolean |
equals(Object o)
Two taxon names are equal if their name and class match. |
String |
getName()
Returns this name. |
String |
getNameClass()
Returns the class of this name. |
int |
hashCode()
|
void |
setName(String name)
Changes the name. |
void |
setNameClass(String nameClass)
Changes the class of this name. |
String |
toString()
Form: "class:name" |
Methods inherited from class java.lang.Object |
---|
clone, finalize, getClass, notify, notifyAll, wait, wait, wait |
Constructor Detail |
---|
protected SimpleNCBITaxonName()
public SimpleNCBITaxonName(String nameClass, String name)
nameClass
- the class of the new name. Use one of the constants from
NCBITaxon
(for example NCBITaxon.SCIENTIFIC
).name
- the name itselfMethod Detail |
---|
public void setNameClass(String nameClass)
nameClass
- the new class for this name.public String getNameClass()
public void setName(String name)
name
- the new name.public String getName()
public boolean equals(Object o)
equals
in class Object
public int compareTo(Object o)
compareTo
in interface Comparable
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 |