Class: IB::Messages::Incoming::OptionChainDefinition

Inherits:
Object
  • Object
show all
Defined in:
lib/ib/messages/incoming.rb

Instance Method Summary collapse

Instance Method Details

#expirationsObject



115
116
117
# File 'lib/ib/messages/incoming.rb', line 115

def expirations
	@data[:expirations]
end

#loadObject



110
111
112
113
114
# File 'lib/ib/messages/incoming.rb', line 110

def load
	super
	load_map 	[:expirations, :array, proc {  @buffer.read_date }],
						[:strikes, :array, proc {  @buffer.read_decimal } ]
end

#strikesObject



118
119
120
# File 'lib/ib/messages/incoming.rb', line 118

def strikes
	@data[:strikes]
end

#to_humanObject



122
123
124
# File 'lib/ib/messages/incoming.rb', line 122

def to_human
	"OptionChainDefinition #{trading_class}@#{exchange} [#{multiplier} X ] strikes: #{strikes.first} - #{strikes.last} expirations: #{expirations.first} - #{expirations.last}"
end