Class: MenuMarkupParser::Attributes

Inherits:
Node
  • Object
show all
Defined in:
lib/menu_markup_parser.rb

Constant Summary collapse

SPICY_MAP =
{
    'n' => 'none',
    'm' => 'mild',
    'M' => 'medium',
    'H' => 'hot', # h = halal!
}
RESTRICTIONS_MAP =

h = halal!

{
    'V' => 'vegan',
    'v' => 'vegetarian',
    'k' => 'kosher',
    'h' => 'halal'
}

Instance Method Summary collapse

Instance Method Details

#restrictionsObject



113
114
115
# File 'lib/menu_markup_parser.rb', line 113

def restrictions
  map(RESTRICTIONS_MAP)
end

#spicyObject



117
118
119
# File 'lib/menu_markup_parser.rb', line 117

def spicy
  map(SPICY_MAP).first
end