T - the type of the market data handled by the filterI - the type of the market data ID handled by the filterpublic interface MarketDataFilter<T,I extends MarketDataId<T>>
A ScenarioPerturbation encapsulates a specific change to a piece of market data, such as a parallel shift.
An implementation of this filter interface defines when the perturbation should be used.
For example, a filter could apply to all yield curves whose currency is USD, or quoted prices
of equity securities in the energy sector.
Implementations must be immutable and thread-safe beans.
| Modifier and Type | Method and Description |
|---|---|
Class<?> |
getMarketDataIdType()
Returns the type of market data ID handled by this filter.
|
boolean |
matches(I marketDataId,
MarketDataBox<T> marketData,
ReferenceData refData)
Applies the filter to a market data ID and the corresponding market data value
and returns true if the filter matches.
|
static <T> MarketDataFilter<T,MarketDataId<T>> |
ofId(MarketDataId<T> id)
Obtains a filter that matches the specified identifier.
|
static <T> MarketDataFilter<T,MarketDataId<T>> |
ofIdType(Class<? extends MarketDataId<T>> type)
Obtains a filter that matches any value with the specified identifier type.
|
static <T> MarketDataFilter<T,NamedMarketDataId<T>> |
ofName(MarketDataName<T> name)
Obtains a filter that matches the specified name.
|
static <T> MarketDataFilter<T,MarketDataId<T>> ofIdType(Class<? extends MarketDataId<T>> type)
T - the type of market data handled by the filtertype - the type that is matched by this filterstatic <T> MarketDataFilter<T,MarketDataId<T>> ofId(MarketDataId<T> id)
T - the type of market data handled by the filterid - the identifier that is matched by this filterstatic <T> MarketDataFilter<T,NamedMarketDataId<T>> ofName(MarketDataName<T> name)
T - the type of market data handled by the filtername - the name that is matched by this filterClass<?> getMarketDataIdType()
This should correspond to the type parameter I.
boolean matches(I marketDataId, MarketDataBox<T> marketData, ReferenceData refData)
marketDataId - the ID of a piece of market datamarketData - the market data valuerefData - the reference dataCopyright 2009-Present by OpenGamma Inc. and individual contributors
Apache v2 licensed
Additional documentation can be found at strata.opengamma.io.