Class: Xtb::Http::TickPrices
- Defined in:
- lib/xtb/http/tick_prices.rb
Overview
Constant Summary collapse
- TickRecord =
Data.define(:ask, :ask_volume, :bid, :bid_volume, :high, :level, :low, :spread_raw, :spread_table, :symbol, :timestamp)
Instance Method Summary collapse
- #call ⇒ Object
-
#initialize(level, symbols, timestamp) ⇒ TickPrices
constructor
A new instance of TickPrices.
Methods inherited from Command
Constructor Details
#initialize(level, symbols, timestamp) ⇒ TickPrices
Returns a new instance of TickPrices.
10 11 12 13 14 15 16 |
# File 'lib/xtb/http/tick_prices.rb', line 10 def initialize(level, symbols, ) @level = level @symbols = symbols @timestamp = super() end |
Instance Method Details
#call ⇒ Object
18 19 20 |
# File 'lib/xtb/http/tick_prices.rb', line 18 def call super.return_data[:quotations].map { |record| TickRecord.new(**record) } end |