Class: Bio::Taxonomy

Inherits:
Object show all
Defined in:
lib/bio/db/phyloxml/phyloxml_elements.rb

Overview

This is general Taxonomy class.

Direct Known Subclasses

PhyloXML::Taxonomy

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initializeTaxonomy

Returns a new instance of Taxonomy.



63
64
65
66
# File 'lib/bio/db/phyloxml/phyloxml_elements.rb', line 63

def initialize
  @common_names = []
  @synonyms = []
end

Instance Attribute Details

#authorityObject

is used to keep the authority, such as ‘J. G. Cooper, 1863’, associated with the ‘scientific_name’.



57
58
59
# File 'lib/bio/db/phyloxml/phyloxml_elements.rb', line 57

def authority
  @authority
end

#codeObject

pattern = [a-zA-Z0-9_]2,10 Can refer to any code/abbreviation/mnemonic, such as Bsu for Bacillus subtilis.



39
40
41
# File 'lib/bio/db/phyloxml/phyloxml_elements.rb', line 39

def code
  @code
end

#common_namesObject

An array of strings



44
45
46
# File 'lib/bio/db/phyloxml/phyloxml_elements.rb', line 44

def common_names
  @common_names
end

#rankObject

value comes from list: domain kingdom, subkingdom, branch, infrakingdom, superphylum, phylum, subphylum, infraphylum, microphylum, superdivision, division, subdivision, infradivision, superclass, class, subclass, infraclass, superlegion, legion, sublegion, infralegion, supercohort, cohort, subcohort, infracohort, superorder, order, suborder, superfamily, family, subfamily, supertribe, tribe, subtribe, infratribe, genus, subgenus, superspecies, species, subspecies, variety, subvariety, form, subform, cultivar, unknown, other



54
55
56
# File 'lib/bio/db/phyloxml/phyloxml_elements.rb', line 54

def rank
  @rank
end

#scientific_nameObject

String.



42
43
44
# File 'lib/bio/db/phyloxml/phyloxml_elements.rb', line 42

def scientific_name
  @scientific_name
end

#synonymsObject

An array of strings. Holds synonyms for scientific names or common names.



60
61
62
# File 'lib/bio/db/phyloxml/phyloxml_elements.rb', line 60

def synonyms
  @synonyms
end