Class: Xtb::Http::News
Overview
Constant Summary collapse
- NewsTopicRecord =
Data.define(:body, :bodylen, :key, :time, :time_string, :title)
Instance Method Summary collapse
- #call ⇒ Object
-
#initialize(end_time, start_time) ⇒ News
constructor
A new instance of News.
Methods inherited from Command
Constructor Details
#initialize(end_time, start_time) ⇒ News
Returns a new instance of News.
11 12 13 14 15 16 |
# File 'lib/xtb/http/news.rb', line 11 def initialize(end_time, start_time) @end_time = end_time @start_time = start_time super() end |
Instance Method Details
#call ⇒ Object
18 19 20 |
# File 'lib/xtb/http/news.rb', line 18 def call super.return_data.map { |record| NewsTopicRecord.new(**record) } end |