Class: CarnesyDerivados

Inherits:
Alimento show all
Defined in:
lib/nutrientes/alimento.rb

Instance Attribute Summary

Attributes inherited from Alimento

#glucidos, #indexglucosa, #lipidos, #nombre, #proteinas

Instance Method Summary collapse

Methods inherited from Alimento

#<=>, #calculate_index, #v_energetico

Constructor Details

#initialize(nombre, p, g, l) ⇒ CarnesyDerivados

Returns a new instance of CarnesyDerivados



83
84
85
# File 'lib/nutrientes/alimento.rb', line 83

def initialize(nombre, p, g, l)
	super(nombre, p, g, l)
end

Instance Method Details

#to_sObject

Converts the object into a string



88
89
90
# File 'lib/nutrientes/alimento.rb', line 88

def to_s
	return "Nombre: #{@nombre}, Proteinas: #{@proteinas}gr, GlĂșcidos: #{@glucidos}gr, Lipidos: #{@lipidos}gr Grupo: Carnes y derivados"
end