Class: MtGox::Ask
Direct Known Subclasses
Constant Summary
Constants included from Value
Instance Attribute Summary
Attributes inherited from Offer
Instance Method Summary collapse
- #eprice ⇒ Object
-
#initialize(hash = nil) ⇒ Ask
constructor
A new instance of Ask.
Methods included from Value
#floatify, #intify, #value_bitcoin, #value_currency
Constructor Details
#initialize(hash = nil) ⇒ Ask
Returns a new instance of Ask.
8 9 10 11 12 13 14 |
# File 'lib/mtgox/ask.rb', line 8 def initialize(hash = nil) if hash self.price = value_currency hash, 'price_int' self.amount = value_bitcoin hash, 'amount_int' self. = hash['stamp'] end end |
Instance Method Details
#eprice ⇒ Object
16 17 18 |
# File 'lib/mtgox/ask.rb', line 16 def eprice price / (1 - MtGox.commission) end |