Package org.forester.go
Class BasicGoTerm
- java.lang.Object
-
- org.forester.go.BasicGoTerm
-
- All Implemented Interfaces:
java.lang.Comparable<GoTerm>,GoTerm,PhylogenyData
public class BasicGoTerm extends java.lang.Object implements GoTerm
-
-
Constructor Summary
Constructors Constructor Description BasicGoTerm(java.lang.String id, java.lang.String name, java.lang.String namespace, boolean is_obsolete)BasicGoTerm(GoId id, java.lang.String name, GoNameSpace namespace, boolean is_obsolete)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description java.lang.StringBufferasSimpleText()java.lang.StringBufferasText()intcompareTo(GoTerm go_term)Compares based on GO id.PhylogenyDatacopy()Makes a shallow copy.booleanequals(java.lang.Object o)Return true if both GO id and namespace are equal.java.util.List<GoId>getAltIds()java.lang.StringgetComment()java.lang.StringgetDefinition()GoIdgetGoId()GoNameSpacegetGoNameSpace()java.util.List<GoRelationship>getGoRelationships()java.util.List<GoSubset>getGoSubsets()java.util.List<GoXRef>getGoXRefs()java.lang.StringgetName()java.util.List<GoId>getSuperGoIds()inthashCode()Hashcode is based on hashcode of GO id.booleanisEqual(PhylogenyData go_term)Compares this PhylogenyData to PhylogenyData data.booleanisObsolete()voidsetComment(java.lang.String comment)voidsetDefinition(java.lang.String definition)voidsetGoSubsets(java.util.List<GoSubset> go_subsets)java.lang.StringBuffertoNHX()voidtoPhyloXML(java.io.Writer writer, int level, java.lang.String indentation)Writes a phyloXML representation of this phylogeny data.java.lang.StringtoString()
-
-
-
Constructor Detail
-
BasicGoTerm
public BasicGoTerm(GoId id, java.lang.String name, GoNameSpace namespace, boolean is_obsolete)
-
BasicGoTerm
public BasicGoTerm(java.lang.String id, java.lang.String name, java.lang.String namespace, boolean is_obsolete)
-
-
Method Detail
-
asSimpleText
public java.lang.StringBuffer asSimpleText()
- Specified by:
asSimpleTextin interfacePhylogenyData
-
asText
public java.lang.StringBuffer asText()
- Specified by:
asTextin interfacePhylogenyData
-
compareTo
public int compareTo(GoTerm go_term)
Compares based on GO id.- Specified by:
compareToin interfacejava.lang.Comparable<GoTerm>
-
copy
public PhylogenyData copy()
Makes a shallow copy.- Specified by:
copyin interfacePhylogenyData- Returns:
- a ~deep~ copy of this PhylogenyData
-
equals
public boolean equals(java.lang.Object o)
Return true if both GO id and namespace are equal.- Overrides:
equalsin classjava.lang.Object
-
getComment
public java.lang.String getComment()
- Specified by:
getCommentin interfaceGoTerm
-
getDefinition
public java.lang.String getDefinition()
- Specified by:
getDefinitionin interfaceGoTerm
-
getGoNameSpace
public GoNameSpace getGoNameSpace()
- Specified by:
getGoNameSpacein interfaceGoTerm
-
getGoRelationships
public java.util.List<GoRelationship> getGoRelationships()
- Specified by:
getGoRelationshipsin interfaceGoTerm
-
getGoSubsets
public java.util.List<GoSubset> getGoSubsets()
- Specified by:
getGoSubsetsin interfaceGoTerm
-
getGoXRefs
public java.util.List<GoXRef> getGoXRefs()
- Specified by:
getGoXRefsin interfaceGoTerm
-
getSuperGoIds
public java.util.List<GoId> getSuperGoIds()
- Specified by:
getSuperGoIdsin interfaceGoTerm
-
hashCode
public int hashCode()
Hashcode is based on hashcode of GO id.- Overrides:
hashCodein classjava.lang.Object
-
isEqual
public boolean isEqual(PhylogenyData go_term)
Description copied from interface:PhylogenyDataCompares this PhylogenyData to PhylogenyData data. In general, this should return true if and only if all fiels are exactly identical.- Specified by:
isEqualin interfacePhylogenyData- Returns:
- in general, true if and only if all fiels are exactly identical, false otherwise
-
isObsolete
public boolean isObsolete()
- Specified by:
isObsoletein interfaceGoTerm
-
setComment
public void setComment(java.lang.String comment)
-
setDefinition
public void setDefinition(java.lang.String definition)
-
setGoSubsets
public void setGoSubsets(java.util.List<GoSubset> go_subsets)
-
toNHX
public java.lang.StringBuffer toNHX()
- Specified by:
toNHXin interfacePhylogenyData
-
toPhyloXML
public void toPhyloXML(java.io.Writer writer, int level, java.lang.String indentation) throws java.io.IOExceptionDescription copied from interface:PhylogenyDataWrites a phyloXML representation of this phylogeny data.- Specified by:
toPhyloXMLin interfacePhylogenyData- Throws:
java.io.IOException
-
toString
public java.lang.String toString()
- Overrides:
toStringin classjava.lang.Object
-
-