Class: Dtn::Lookups::Historical::IntervalDay
- Defined in:
- lib/dtn/lookups/historical/interval_day.rb
Overview
Interval datapoint requests
Constant Summary collapse
- TEMPLATE =
"HID,%<symbol>s,%<interval>d,%<days>d,%<max_datapoints>d,%<begin_filter_time>s,"\ "%<end_filter_time>s,%<data_direction>d,%<id>d,%<datapoints_per_send>d,%<interval_type>s"
Constants inherited from Base
Base::DEFAULT_BEGIN_FILTER_TIME, Base::DEFAULT_DATAPOINTS_PER_SEND, Base::DEFAULT_DATA_DIRECTION, Base::DEFAULT_END_FILTER_TIME, Base::DEFAULT_MAX_DATAPOINTS
Constants included from Concerns::Validation
Concerns::Validation::DATE_FORMAT, Concerns::Validation::DATE_TIME_FORMAT, Concerns::Validation::DEFAULT_INTERVAL_TYPE, Concerns::Validation::MAX_INT16
Constants inherited from Request
Request::END_OF_MESSAGE_CHARACTERS, Request::NO_DATA_CHARACTERS, Request::PORT, Request::SYNTAX_ERROR_CHARACTERS
Instance Attribute Summary
Attributes inherited from Request
Instance Method Summary collapse
-
#call(symbol:, interval:, days:, **options) ⇒ Object
HID - Retrieves [Days] days of interval data for the specified [Symbol].
Methods inherited from Interval
Methods inherited from Request
Methods included from Concerns::Id
Instance Method Details
#call(symbol:, interval:, days:, **options) ⇒ Object
HID - Retrieves [Days] days of interval data for the specified [Symbol].
Example message
HID,[Symbol],[Interval],[Days],[MaxDatapoints],[BeginFilterTime],[EndFilterTime],
[DataDirection],[RequestID],[DatapointsPerSend],[IntervalType]<CR><LF>
18 19 20 21 22 23 24 25 26 27 28 |
# File 'lib/dtn/lookups/historical/interval_day.rb', line 18 def call(symbol:, interval:, days:, **) self. = defaults(**).merge( { symbol: validate_symbol(symbol), days: validate_short_int(days), interval: validate_int(interval), interval_type: validate_interval_type([:interval_type]) } ) super end |