Class: Fugle::Trade Private
- Inherits:
-
Object
- Object
- Fugle::Trade
- Defined in:
- lib/fugle/trade.rb
Overview
This class is part of a private API. You should avoid using this class if possible, as it may be removed or be changed in the future.
The trade information
Instance Attribute Summary collapse
- #order ⇒ Object readonly private
- #price ⇒ Object readonly private
- #serial ⇒ Object readonly private
- #unit ⇒ Object readonly private
- #volume ⇒ Object readonly private
Instance Method Summary collapse
-
#initialize(item) ⇒ Trade
constructor
private
A new instance of Trade.
Constructor Details
#initialize(item) ⇒ Trade
This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.
Returns a new instance of Trade.
15 16 17 18 19 20 21 22 |
# File 'lib/fugle/trade.rb', line 15 def initialize(item) @price = item['price'] @unit = item['unit'] @order = item['order'] @volume = item['volume'] @serial = item['serial'] @at = DateTime.parse(item['at']) if item['at'] end |
Instance Attribute Details
#order ⇒ Object (readonly)
This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.
11 12 13 |
# File 'lib/fugle/trade.rb', line 11 def order @order end |
#price ⇒ Object (readonly)
This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.
11 12 13 |
# File 'lib/fugle/trade.rb', line 11 def price @price end |
#serial ⇒ Object (readonly)
This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.
11 12 13 |
# File 'lib/fugle/trade.rb', line 11 def serial @serial end |
#unit ⇒ Object (readonly)
This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.
11 12 13 |
# File 'lib/fugle/trade.rb', line 11 def unit @unit end |
#volume ⇒ Object (readonly)
This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.
11 12 13 |
# File 'lib/fugle/trade.rb', line 11 def volume @volume end |