Class: FishTank::Tank
- Inherits:
-
Object
- Object
- FishTank::Tank
- Defined in:
- lib/fishtank/tank.rb
Instance Attribute Summary collapse
-
#taxa ⇒ Object
Returns the value of attribute taxa.
Instance Method Summary collapse
- #add(taxon) ⇒ Object
-
#initialize ⇒ Tank
constructor
A new instance of Tank.
Constructor Details
#initialize ⇒ Tank
Returns a new instance of Tank.
7 8 9 |
# File 'lib/fishtank/tank.rb', line 7 def initialize @taxa = [] end |
Instance Attribute Details
#taxa ⇒ Object
Returns the value of attribute taxa.
5 6 7 |
# File 'lib/fishtank/tank.rb', line 5 def taxa @taxa end |
Instance Method Details
#add(taxon) ⇒ Object
11 12 13 |
# File 'lib/fishtank/tank.rb', line 11 def add(taxon) @taxa.push(taxon) end |