Class: Alimento::Grupoal
Instance Attribute Summary
Attributes inherited from Alimento
Instance Method Summary collapse
-
#initialize(grupo, nombre, prt, gluc, lip) ⇒ Grupoal
constructor
A new instance of Grupoal.
- #to_s ⇒ Object
Methods inherited from Alimento
Constructor Details
#initialize(grupo, nombre, prt, gluc, lip) ⇒ Grupoal
Returns a new instance of Grupoal.
34 35 36 37 |
# File 'lib/alimento.rb', line 34 def initialize(grupo,nombre,prt,gluc,lip) super(nombre,prt,gluc,lip) @grupo=grupo end |
Instance Method Details
#to_s ⇒ Object
38 39 40 |
# File 'lib/alimento.rb', line 38 def to_s puts @grupo+"\n\t"+super.to_s end |