Class: CoinSync::Importers::ArkVoting::HistoryEntry
- Inherits:
-
Object
- Object
- CoinSync::Importers::ArkVoting::HistoryEntry
- Defined in:
- lib/coinsync/importers/ark_voting.rb
Instance Attribute Summary collapse
-
#amount ⇒ Object
Returns the value of attribute amount.
-
#timestamp ⇒ Object
Returns the value of attribute timestamp.
Instance Method Summary collapse
-
#initialize(hash) ⇒ HistoryEntry
constructor
A new instance of HistoryEntry.
Constructor Details
#initialize(hash) ⇒ HistoryEntry
Returns a new instance of HistoryEntry.
25 26 27 28 |
# File 'lib/coinsync/importers/ark_voting.rb', line 25 def initialize(hash) @timestamp = EPOCH_TIME + hash['timestamp'] @amount = BigDecimal.new(hash['amount']) / 100_000_000 end |
Instance Attribute Details
#amount ⇒ Object
Returns the value of attribute amount.
23 24 25 |
# File 'lib/coinsync/importers/ark_voting.rb', line 23 def amount @amount end |
#timestamp ⇒ Object
Returns the value of attribute timestamp.
23 24 25 |
# File 'lib/coinsync/importers/ark_voting.rb', line 23 def @timestamp end |