Class: StockTracker::PastQuote

Inherits:
Object
  • Object
show all
Includes:
YahooFinance
Defined in:
lib/stocktracker.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(symbol, date) ⇒ PastQuote

Returns a new instance of PastQuote.



80
81
82
83
84
# File 'lib/stocktracker.rb', line 80

def initialize(symbol, date)
  self.symbol = symbol
  self.date = date
  self.results = yahoo_past_quote
end

Instance Attribute Details

#dateObject

Returns the value of attribute date.



79
80
81
# File 'lib/stocktracker.rb', line 79

def date
  @date
end

#resultsObject

Returns the value of attribute results.



79
80
81
# File 'lib/stocktracker.rb', line 79

def results
  @results
end

#symbolObject

Returns the value of attribute symbol.



79
80
81
# File 'lib/stocktracker.rb', line 79

def symbol
  @symbol
end

Instance Method Details

#cacheObject



75
76
77
# File 'lib/stocktracker.rb', line 75

def cache
  StockTracker.cache
end