Class: AMarmita::Cart::Scrapper

Inherits:
Scrapper
  • Object
show all
Defined in:
lib/a_marmita/cart/scrapper.rb

Instance Attribute Summary

Attributes inherited from Scrapper

#attributes, #css_parser

Instance Method Summary collapse

Methods inherited from Scrapper

#initialize, #scrap, #to_hash, #valid?

Constructor Details

This class inherits a constructor from AMarmita::Scrapper

Instance Method Details

#run(options = {}) ⇒ Object



9
10
11
12
13
14
15
16
# File 'lib/a_marmita/cart/scrapper.rb', line 9

def run(options = {})
  @attributes = {
    date: options[:date],
    id: Helpers.to_int(get_id),
    description: get_description,
    quantity: Helpers.to_int(get_quantity)
  }
end