Class: Powershop::Register
- Inherits:
-
Object
- Object
- Powershop::Register
- Defined in:
- lib/powershop/register.rb
Constant Summary collapse
- ATTRIBUTES =
%w(register_number description dials hidden last_reading_at last_reading_value last_reading_type estimated_reading_value)
Instance Method Summary collapse
-
#initialize(hash) ⇒ Register
constructor
A new instance of Register.
Constructor Details
#initialize(hash) ⇒ Register
Returns a new instance of Register.
9 10 11 12 13 |
# File 'lib/powershop/register.rb', line 9 def initialize(hash) ATTRIBUTES.each do |r| send("#{r}=", hash[r]) end end |