Class: DssReuters::Api
- Inherits:
-
Object
- Object
- DssReuters::Api
- Defined in:
- lib/dss_reuters.rb
Instance Method Summary collapse
- #extract_with_isin(isin_code, type = :composite, fields = nil, condition = nil) ⇒ Object
- #extract_with_location(location) ⇒ Object
- #get_user ⇒ Object
-
#initialize ⇒ Api
constructor
A new instance of Api.
Constructor Details
#initialize ⇒ Api
Returns a new instance of Api.
161 162 163 |
# File 'lib/dss_reuters.rb', line 161 def initialize @session = Session.new end |
Instance Method Details
#extract_with_isin(isin_code, type = :composite, fields = nil, condition = nil) ⇒ Object
173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 |
# File 'lib/dss_reuters.rb', line 173 def extract_with_isin(isin_code, type=:composite, fields=nil, condition=nil) fields ||= [ "Close Price", "Contributor Code Description", "Currency Code Description", "Dividend Yield", "Main Index", "Market Capitalization", "Market Capitalization - Local Currency", "Percent Change - Close Price - 1 Day", "Universal Close Price Date" ] identifiers = [ { "Identifier" => isin_code, "IdentifierType" => "Isin" } ] OnDemandExtract.new(@session, identifiers, type, fields, condition) end |
#extract_with_location(location) ⇒ Object
169 170 171 |
# File 'lib/dss_reuters.rb', line 169 def extract_with_location(location) OnDemandExtract.init_with_location(@session, location) end |
#get_user ⇒ Object
165 166 167 |
# File 'lib/dss_reuters.rb', line 165 def get_user @user = User.new(@session) end |