org.mov.quote
Interface QuoteFunctionSource
- All Known Implementing Classes:
- GraphableQuoteFunctionSource, QuoteBundleFunctionSource
public interface QuoteFunctionSource
This interface describes the quote source for the quote functions
in QuoteFunctions
. That class is used by both Gondola language
expressions and charting functions, so it needs to accept quotes in multiple
forms. This interface enables the quote function class to be unaware of
this difference.
- Author:
- Andrew Leppard
- See Also:
QuoteFunctions
Method Summary |
double |
getValue(int offset)
Return the quote value on the given date. |
getValue
double getValue(int offset)
throws EvaluationException
- Return the quote value on the given date. The quote function source
contains a set of quotes which can be accessed from offset 0, which
is the earliest date, to the number of quotes in the source minus one.
Typically a quote source is set up to contain a fixed number of quotes,
each of which is used by a quote function.
- Parameters:
offset
- the offset of the date in the quote source.
- Returns:
- the quote value or
NaN
if the quote is missing / not available
- Throws:
EvaluationException
- if QuoteBundleFunctionSource
is not
allowed access to a quote. See GPQuoteBundle
.