class GrupoAlimento

Attributes

tipo[RW]

Public Class Methods

new(nodo, tipo) click to toggle source
# File lib/menu/GrupoAlimento.rb, line 4
def initialize(nodo, tipo)
    @head = nodo
    @size = 1
    @tail = nodo  
    @head.prev = nil
    @tipo = tipo
end

Public Instance Methods

to_s() click to toggle source
Calls superclass method Lista#to_s
# File lib/menu/GrupoAlimento.rb, line 11
def to_s
    s = ""
    s << "#{@tipo}\n"
    s << super.to_s
end