Class: Cobrato::Resources::ChargingType
- Defined in:
- lib/cobrato/resources/charging_type.rb
Instance Attribute Summary
Attributes inherited from Base
Instance Method Summary collapse
Methods inherited from Base
#collection_name, #create, crud, #destroy, #initialize, #parsed_body, #show, #update
Methods included from Hooks
Constructor Details
This class inherits a constructor from Cobrato::Resources::Base
Instance Method Details
#list ⇒ Object
6 7 8 9 10 11 12 13 14 |
# File 'lib/cobrato/resources/charging_type.rb', line 6 def list http.get(resource_base_path) do |response| bank_billets = parsed_body(response)[collection_name]['bank_billets'].map do |item| Cobrato::Entities::BankBillet.new(item) end Struct.new(:bank_billets).new(bank_billets) end end |