Class: IB::Messages::Incoming::MarketDepth
- Defined in:
- lib/ib/messages/incoming/market_depths.rb
Instance Method Summary collapse
Instance Method Details
#operation ⇒ Object
21 22 23 |
# File 'lib/ib/messages/incoming/market_depths.rb', line 21 def operation @data[:operation] == 0 ? :insert : @data[:operation] == 1 ? :update : :delete end |
#side ⇒ Object
17 18 19 |
# File 'lib/ib/messages/incoming/market_depths.rb', line 17 def side @data[:side] == 0 ? :ask : :bid end |
#to_human ⇒ Object
25 26 27 28 |
# File 'lib/ib/messages/incoming/market_depths.rb', line 25 def to_human "<#{self.}: #{operation} #{side} @ "+ "#{position} = #{price} x #{size}>" end |