Class: Mspire::OBO
- Inherits:
-
Object
- Object
- Mspire::OBO
- Defined in:
- lib/mspire/obo.rb
Instance Attribute Summary collapse
-
#elements ⇒ Object
Returns the value of attribute elements.
-
#header ⇒ Object
Returns the value of attribute header.
Instance Method Summary collapse
- #id_to_element ⇒ Object
-
#id_to_name ⇒ Object
returns an id to name Hash.
-
#initialize(file_or_io) ⇒ OBO
constructor
A new instance of OBO.
-
#name_to_id ⇒ Object
returns a name to id Hash.
Constructor Details
Instance Attribute Details
#elements ⇒ Object
Returns the value of attribute elements.
5 6 7 |
# File 'lib/mspire/obo.rb', line 5 def elements @elements end |
#header ⇒ Object
Returns the value of attribute header.
4 5 6 |
# File 'lib/mspire/obo.rb', line 4 def header @header end |
Instance Method Details
#id_to_element ⇒ Object
20 21 22 |
# File 'lib/mspire/obo.rb', line 20 def id_to_element @id_to_element ||= build_hash('id', nil) end |
#id_to_name ⇒ Object
returns an id to name Hash
13 14 15 |
# File 'lib/mspire/obo.rb', line 13 def id_to_name @id_to_name ||= build_hash('id', 'name') end |
#name_to_id ⇒ Object
returns a name to id Hash
17 18 19 |
# File 'lib/mspire/obo.rb', line 17 def name_to_id @name_to_id ||= build_hash('name', 'id') end |