public final class ConstantRecoveryRates extends Object implements RecoveryRates, org.joda.beans.ImmutableBean, Serializable
The recovery rate is constant for any given date.
| Modifier and Type | Class and Description |
|---|---|
static class |
ConstantRecoveryRates.Meta
The meta-bean for
ConstantRecoveryRates. |
| Modifier and Type | Method and Description |
|---|---|
boolean |
equals(Object obj) |
<T> Optional<T> |
findData(MarketDataName<T> name) |
StandardId |
getLegalEntityId()
Gets the legal entity identifier.
|
double |
getParameter(int parameterIndex) |
int |
getParameterCount() |
ParameterMetadata |
getParameterMetadata(int parameterIndex) |
double |
getRecoveryRate()
Gets the recovery rate.
|
LocalDate |
getValuationDate()
Gets the valuation date.
|
int |
hashCode() |
static ConstantRecoveryRates.Meta |
meta()
The meta-bean for
ConstantRecoveryRates. |
ConstantRecoveryRates.Meta |
metaBean() |
static ConstantRecoveryRates |
of(StandardId legalEntityId,
LocalDate valuationDate,
double recoveryRate)
Obtains an instance.
|
double |
recoveryRate(LocalDate date)
Gets the recovery rate for the specified date.
|
String |
toString() |
ConstantRecoveryRates |
withParameter(int parameterIndex,
double newValue) |
ConstantRecoveryRates |
withPerturbation(ParameterPerturbation perturbation) |
clone, finalize, getClass, notify, notifyAll, wait, wait, waitoffindParameterIndexpublic static ConstantRecoveryRates of(StandardId legalEntityId, LocalDate valuationDate, double recoveryRate)
legalEntityId - the legal entity identifiervaluationDate - the valuation daterecoveryRate - the recovery ratepublic 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 ConstantRecoveryRates withParameter(int parameterIndex, double newValue)
withParameter in interface ParameterizedDatawithParameter in interface RecoveryRatespublic ConstantRecoveryRates withPerturbation(ParameterPerturbation perturbation)
withPerturbation in interface ParameterizedDatawithPerturbation in interface RecoveryRatespublic static ConstantRecoveryRates.Meta meta()
ConstantRecoveryRates.public ConstantRecoveryRates.Meta 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 double getRecoveryRate()
The recovery rate is represented in decimal form, and must be between 0 and 1 inclusive.
Copyright 2009-Present by OpenGamma Inc. and individual contributors
Apache v2 licensed
Additional documentation can be found at strata.opengamma.io.