Class: Easee::Charger
- Inherits:
-
Object
- Object
- Easee::Charger
- Defined in:
- lib/easee/charger.rb
Instance Method Summary collapse
- #color ⇒ Object
- #id ⇒ Object
-
#initialize(data) ⇒ Charger
constructor
A new instance of Charger.
- #name ⇒ Object
- #product_code ⇒ Object
Constructor Details
#initialize(data) ⇒ Charger
Returns a new instance of Charger.
3 4 5 |
# File 'lib/easee/charger.rb', line 3 def initialize(data) @data = data.symbolize_keys end |
Instance Method Details
#color ⇒ Object
9 |
# File 'lib/easee/charger.rb', line 9 def color = @data.fetch(:color) |
#id ⇒ Object
7 |
# File 'lib/easee/charger.rb', line 7 def id = @data.fetch(:id) |
#name ⇒ Object
8 |
# File 'lib/easee/charger.rb', line 8 def name = @data.fetch(:name) |
#product_code ⇒ Object
10 |
# File 'lib/easee/charger.rb', line 10 def product_code = @data.fetch(:productCode) |