Sha256: 021d4340b2da91a4392cfc8ad4784f625b2b8f770d2b5b8a67337dfc7b4658e6

Contents?: true

Size: 1.57 KB

Versions: 6

Compression:

Stored size: 1.57 KB

Contents

module IEX
  module Resources
    class HistorialPrices < Resource
      property 'date'
      property 'open'
      property 'open_dollar', from: 'open', with: ->(v) { to_dollar(amount: v, ignore_cents: false) }
      property 'close'
      property 'close_dollar', from: 'close', with: ->(v) { to_dollar(amount: v, ignore_cents: false) }
      property 'high'
      property 'high_dollar', from: 'high', with: ->(v) { to_dollar(amount: v, ignore_cents: false) }
      property 'low'
      property 'low_dollar', from: 'low', with: ->(v) { to_dollar(amount: v, ignore_cents: false) }
      property 'volume'
      property 'u_open', from: 'uOpen'
      property 'u_open_dollar', from: 'uOpen', with: ->(v) { to_dollar(amount: v, ignore_cents: false) }
      property 'u_close', from: 'uClose'
      property 'u_close_dollar', from: 'uClose', with: ->(v) { to_dollar(amount: v, ignore_cents: false) }
      property 'u_low', from: 'uLow'
      property 'u_low_dollar', from: 'uLow', with: ->(v) { to_dollar(amount: v, ignore_cents: false) }
      property 'u_high', from: 'uHigh'
      property 'u_high_dollar', from: 'uHigh', with: ->(v) { to_dollar(amount: v, ignore_cents: false) }
      property 'u_volume', from: 'uVolume'
      property 'change'
      property 'change_percent', from: 'changePercent'
      property 'change_percent_s', from: 'changePercent', with: ->(v) { percentage_to_string(v) }
      property 'label'
      property 'change_over_time', from: 'changeOverTime'
      property 'change_over_time_s', from: 'changeOverTime', with: ->(v) { percentage_to_string(v) }
    end
  end
end

Version data entries

6 entries across 6 versions & 1 rubygems

Version Path
iex-ruby-client-2.1.0 lib/iex/resources/historical_prices.rb
iex-ruby-client-2.0.0 lib/iex/resources/historical_prices.rb
iex-ruby-client-1.6.0 lib/iex/resources/historical_prices.rb
iex-ruby-client-1.5.0 lib/iex/resources/historical_prices.rb
iex-ruby-client-1.4.1 lib/iex/resources/historical_prices.rb
iex-ruby-client-1.4.0 lib/iex/resources/historical_prices.rb