Sha256: 76a006fe4879bc99b7244a78e3856c6b4d92f14f6b0d6f3fb7515dc278691217
Contents?: true
Size: 1.17 KB
Versions: 13
Compression:
Stored size: 1.17 KB
Contents
module IB module Messages module Incoming # RealTimeBar contains following @data: # :request_id - The ID of the *request* to which this is responding # :time - The date-time stamp of the start of the bar. The format is offset in # seconds from the beginning of 1970, same format as the UNIX epoch time # :bar - received RT Bar RealTimeBar = def_message 50, [:request_id, :int], [:bar, :time, :int], [:bar, :open, :decimal], [:bar, :high, :decimal], [:bar, :low, :decimal], [:bar, :close, :decimal], [:bar, :volume, :int], [:bar, :wap, :decimal], [:bar, :trades, :int] class RealTimeBar def bar @bar = IB::Bar.new @data[:bar] end def to_human "<RealTimeBar: #{request_id} #{time}, #{bar}>" end end # RealTimeBar end # module Incoming end # module Messages end # module IB
Version data entries
13 entries across 13 versions & 1 rubygems