public class SimpleNCBITaxon extends AbstractChangeable implements NCBITaxon
| Modifier and Type | Field and Description |
|---|---|
protected Set |
names |
ACRONYM, COMMON, EQUIVALENT, GENETICCODE, HIDDEN, LEFTVALUE, MITOGENETICCODE, NAMES, NODERANK, PARENT, RIGHTVALUE, SCIENTIFIC, SYNONYM| Modifier | Constructor and Description |
|---|---|
protected |
SimpleNCBITaxon() |
|
SimpleNCBITaxon(int NCBITaxID)
Creates a new instance of SimpleNCBITaxon based on the given taxon ID.
|
|
SimpleNCBITaxon(Integer NCBITaxID)
Creates a new instance of SimpleNCBITaxon based on the given taxon ID.
|
| Modifier and Type | Method and Description |
|---|---|
void |
addName(String nameClass,
String name)
Adds the name to this taxon in the given name class.
|
int |
compareTo(Object o)
NCBITaxon objects are compared only by their NCBITaxID fields.
|
boolean |
containsName(String nameClass,
String name)
Tests for the presence of a name in a given class.
|
boolean |
equals(Object obj)
NCBITaxon objects are equal if their NCBITaxID fields match.
|
String |
getDisplayName()
Returns the name of this taxon entry in the form:
scientific (common)
or if there is no common name:
scientific
or if there are no scientific names at all, the empty string.
|
Integer |
getGeneticCode()
Returns the genetic code of this taxon, which may be null if not known.
|
Integer |
getId()
Gets the Hibernate ID.
|
Integer |
getLeftValue()
Gets the left value.
|
Integer |
getMitoGeneticCode()
Getter for property mitoGeneticCode.
|
Set |
getNameClasses()
Returns all the name classes available for a taxon.
|
String |
getNameHierarchy()
Returns the taxonomy hierarchy of this taxon entry in the form:
most specific; less specific; ...; least specific.
|
Set |
getNames(String nameClass)
Returns all the names available for a taxon in a given class.
|
protected Set |
getNameSet() |
protected Map |
getNamesMap() |
int |
getNCBITaxID()
Gets the NCBI taxon ID.
|
String |
getNodeRank()
Gets the node rank of this taxon.
|
Integer |
getParentNCBITaxID()
Returns the parent NCBI taxon ID, if known.
|
Integer |
getRightValue()
Gets the right value.
|
int |
hashCode() |
boolean |
isTaxonHidden()
Returns the taxonomy hierarchy of this taxon entry in the form:
most specific; less specific; ...; least specific.
|
boolean |
removeName(String nameClass,
String name)
Removes the name from the given name class.
|
void |
setGeneticCode(Integer geneticCode)
Sets the genetic code of this taxon, which may be null, which will unset it.
|
void |
setId(Integer id)
Sets the Hibernate ID.
|
void |
setLeftValue(Integer leftValue)
Sets the left value.
|
void |
setMitoGeneticCode(Integer mitoGeneticCode)
Sets the mitochondrial genetic code of this taxon, which may be null,
which will unset it.
|
void |
setNodeRank(String nodeRank)
Setter for property nodeRank.
|
void |
setParentNCBITaxID(Integer parent)
Sets the parent NCBI taxon ID.
|
void |
setRightValue(Integer rightValue)
Sets the right value.
|
void |
setTaxonHidden(boolean isTaxonHidden)
determines whether this taxonomy level is displayed in etNameHierarchy()
|
String |
toString()
Form: "taxid:[name,name...]"
|
addChangeListener, addChangeListener, generateChangeSupport, getChangeSupport, hasListeners, hasListeners, isUnchanging, removeChangeListener, removeChangeListenerclone, finalize, getClass, notify, notifyAll, wait, wait, waitaddChangeListener, addChangeListener, isUnchanging, removeChangeListener, removeChangeListenerpublic SimpleNCBITaxon(int NCBITaxID)
NCBITaxID - the underlying taxon ID from NCBI.public SimpleNCBITaxon(Integer NCBITaxID)
NCBITaxID - the underlying taxon ID from NCBI.protected SimpleNCBITaxon()
public int compareTo(Object o)
compareTo in interface Comparablepublic boolean equals(Object obj)
public Set getNameClasses()
getNameClasses in interface NCBITaxonpublic Set getNames(String nameClass) throws IllegalArgumentException
getNames in interface NCBITaxonnameClass - the name class to retrieve names from.IllegalArgumentException - if the name is null.protected Set getNameSet()
public void addName(String nameClass, String name) throws IllegalArgumentException, ChangeVetoException
addName in interface NCBITaxonnameClass - the class to add the name in.name - the name to add.IllegalArgumentException - if the name is null.ChangeVetoException - in case of objections.public boolean removeName(String nameClass, String name) throws IllegalArgumentException, ChangeVetoException
removeName in interface NCBITaxonnameClass - the class to remove the name from.name - the name to remove.IllegalArgumentException - if the name is null.ChangeVetoException - in case of objections.public boolean containsName(String nameClass, String name) throws IllegalArgumentException
containsName in interface NCBITaxonnameClass - the class to look the name up in.name - the name to text for existence of.IllegalArgumentException - if the name is null.protected final Map getNamesMap()
public Integer getParentNCBITaxID()
getParentNCBITaxID in interface NCBITaxonpublic void setParentNCBITaxID(Integer parent) throws ChangeVetoException
setParentNCBITaxID in interface NCBITaxonparent - New value of property parent.ChangeVetoException - in case of objections.public int getNCBITaxID()
getNCBITaxID in interface NCBITaxonpublic String getNodeRank()
getNodeRank in interface NCBITaxonpublic void setNodeRank(String nodeRank) throws ChangeVetoException
setNodeRank in interface NCBITaxonnodeRank - New value of property nodeRank.ChangeVetoException - in case of objections.public Integer getGeneticCode()
getGeneticCode in interface NCBITaxonpublic void setGeneticCode(Integer geneticCode) throws ChangeVetoException
setGeneticCode in interface NCBITaxongeneticCode - New value of property geneticCode.ChangeVetoException - in case of objections.public Integer getMitoGeneticCode()
getMitoGeneticCode in interface NCBITaxonpublic void setMitoGeneticCode(Integer mitoGeneticCode) throws ChangeVetoException
setMitoGeneticCode in interface NCBITaxonmitoGeneticCode - New value of property mitoGeneticCode.ChangeVetoException - in case of objections.public Integer getLeftValue()
getLeftValue in interface NCBITaxonpublic void setLeftValue(Integer leftValue) throws ChangeVetoException
setLeftValue in interface NCBITaxonleftValue - New value of property leftValue.ChangeVetoException - in case of objections.public Integer getRightValue()
getRightValue in interface NCBITaxonpublic void setRightValue(Integer rightValue) throws ChangeVetoException
setRightValue in interface NCBITaxonrightValue - New value of property rightValue.ChangeVetoException - in case of objections.public String getDisplayName()
getDisplayName in interface NCBITaxonpublic final boolean isTaxonHidden()
isTaxonHidden in interface NCBITaxonpublic final void setTaxonHidden(boolean isTaxonHidden) throws ChangeVetoException
NCBITaxonsetTaxonHidden in interface NCBITaxonisTaxonHidden - - if true it is displayedChangeVetoExceptionpublic String getNameHierarchy()
getNameHierarchy in interface NCBITaxonpublic Integer getId()
Copyright © 2020 BioJava. All rights reserved.