public final class NodalRecoveryRates extends Object implements RecoveryRates, org.joda.beans.ImmutableBean, Serializable
The underlying curve must contain year fractions against recovery rates, and the day count must be present.
| Modifier and Type | Class and Description |
|---|---|
static class |
NodalRecoveryRates.Builder
The bean-builder for
NodalRecoveryRates. |
| Modifier and Type | Method and Description |
|---|---|
static NodalRecoveryRates.Builder |
builder()
Returns a builder used to create an instance of the bean.
|
boolean |
equals(Object obj) |
<T> Optional<T> |
findData(MarketDataName<T> name) |
NodalCurve |
getCurve()
Gets the underlying curve.
|
StandardId |
getLegalEntityId()
Gets the legal entity identifier.
|
double |
getParameter(int parameterIndex) |
int |
getParameterCount() |
ParameterMetadata |
getParameterMetadata(int parameterIndex) |
LocalDate |
getValuationDate()
Gets the valuation date.
|
int |
hashCode() |
static org.joda.beans.TypedMetaBean<NodalRecoveryRates> |
meta()
The meta-bean for
NodalRecoveryRates. |
org.joda.beans.TypedMetaBean<NodalRecoveryRates> |
metaBean() |
static NodalRecoveryRates |
of(StandardId legalEntityId,
LocalDate valuationDate,
NodalCurve curve)
Obtains an instance.
|
double |
recoveryRate(LocalDate date)
Gets the recovery rate for the specified date.
|
NodalRecoveryRates.Builder |
toBuilder()
Returns a builder that allows this bean to be mutated.
|
String |
toString() |
NodalRecoveryRates |
withCurve(NodalCurve curve)
Returns a new instance with a different curve.
|
NodalRecoveryRates |
withParameter(int parameterIndex,
double newValue) |
NodalRecoveryRates |
withPerturbation(ParameterPerturbation perturbation) |
clone, finalize, getClass, notify, notifyAll, wait, wait, waitoffindParameterIndexpublic static NodalRecoveryRates of(StandardId legalEntityId, LocalDate valuationDate, NodalCurve curve)
The curve is specified by an instance of NodalCurve, such as InterpolatedNodalCurve.
The curve must contain year fractions
against recovery rates, and the day count must be present.
legalEntityId - the legalEntity IDvaluationDate - the valuation date for which the curve is validcurve - the underlying curvepublic double recoveryRate(LocalDate date)
RecoveryRatesrecoveryRate in interface RecoveryRatesdate - the datepublic <T> Optional<T> findData(MarketDataName<T> name)
findData in interface MarketDataViewpublic int getParameterCount()
getParameterCount in interface ParameterizedDatapublic double getParameter(int parameterIndex)
getParameter in interface ParameterizedDatapublic ParameterMetadata getParameterMetadata(int parameterIndex)
getParameterMetadata in interface ParameterizedDatapublic NodalRecoveryRates withParameter(int parameterIndex, double newValue)
withParameter in interface ParameterizedDatawithParameter in interface RecoveryRatespublic NodalRecoveryRates withPerturbation(ParameterPerturbation perturbation)
withPerturbation in interface ParameterizedDatawithPerturbation in interface RecoveryRatespublic NodalRecoveryRates withCurve(NodalCurve curve)
curve - the new curvepublic static org.joda.beans.TypedMetaBean<NodalRecoveryRates> meta()
NodalRecoveryRates.public static NodalRecoveryRates.Builder builder()
public org.joda.beans.TypedMetaBean<NodalRecoveryRates> metaBean()
metaBean in interface org.joda.beans.Beanpublic StandardId getLegalEntityId()
This identifier is used for the reference legal entity of a credit derivative.
getLegalEntityId in interface RecoveryRatespublic LocalDate getValuationDate()
getValuationDate in interface MarketDataViewgetValuationDate in interface RecoveryRatespublic NodalCurve getCurve()
The metadata of the curve must define a day count.
public NodalRecoveryRates.Builder toBuilder()
Copyright 2009-Present by OpenGamma Inc. and individual contributors
Apache v2 licensed
Additional documentation can be found at strata.opengamma.io.