public final class ImmutableIborIndex extends Object implements IborIndex, org.joda.beans.ImmutableBean, Serializable
A standard immutable implementation of IborIndex that defines the currency
and the rules for converting from fixing to effective and maturity.
In most cases, applications should refer to indices by name, using IborIndex.of(String).
The named index will typically be resolved to an instance of this class.
As such, it is recommended to use the IborIndex interface in application
code rather than directly referring to this class.
| Modifier and Type | Class and Description |
|---|---|
static class |
ImmutableIborIndex.Builder
The bean-builder for
ImmutableIborIndex. |
static class |
ImmutableIborIndex.Meta
The meta-bean for
ImmutableIborIndex. |
| Modifier and Type | Method and Description |
|---|---|
static ImmutableIborIndex.Builder |
builder()
Returns a builder used to create an instance of the bean.
|
LocalDate |
calculateEffectiveFromFixing(LocalDate fixingDate,
ReferenceData refData)
Calculates the effective date from the fixing date.
|
ZonedDateTime |
calculateFixingDateTime(LocalDate fixingDate)
Converts the fixing date-time from the fixing date.
|
LocalDate |
calculateFixingFromEffective(LocalDate effectiveDate,
ReferenceData refData)
Calculates the fixing date from the effective date.
|
LocalDate |
calculateMaturityFromEffective(LocalDate effectiveDate,
ReferenceData refData)
Calculates the maturity date from the effective date.
|
LocalDate |
calculateMaturityFromFixing(LocalDate fixingDate,
ReferenceData refData)
Calculates the maturity date from the fixing date.
|
boolean |
equals(Object obj) |
Currency |
getCurrency()
Gets the currency of the index.
|
DayCount |
getDayCount()
Gets the day count convention.
|
DayCount |
getDefaultFixedLegDayCount()
Gets the default day count convention for the associated fixed leg.
|
DaysAdjustment |
getEffectiveDateOffset()
Gets the adjustment applied to the fixing date to obtain the effective date.
|
HolidayCalendarId |
getFixingCalendar()
Gets the calendar that determines which dates are fixing dates.
|
DaysAdjustment |
getFixingDateOffset()
Gets the adjustment applied to the effective date to obtain the fixing date.
|
LocalTime |
getFixingTime()
Gets the fixing time.
|
ZoneId |
getFixingZone()
Gets the fixing time-zone.
|
FloatingRateName |
getFloatingRateName()
Gets the floating rate name for this index.
|
TenorAdjustment |
getMaturityDateOffset()
Gets the adjustment applied to the effective date to obtain the maturity date.
|
String |
getName()
Gets the index name, such as 'GBP-LIBOR-3M'.
|
Tenor |
getTenor()
Gets the tenor of the index.
|
int |
hashCode() |
boolean |
isActive()
Gets whether the index is active, defaulted to true.
|
static ImmutableIborIndex.Meta |
meta()
The meta-bean for
ImmutableIborIndex. |
ImmutableIborIndex.Meta |
metaBean() |
Function<LocalDate,IborIndexObservation> |
resolve(ReferenceData refData)
Resolves this index using the specified reference data, returning a function.
|
ImmutableIborIndex.Builder |
toBuilder()
Returns a builder that allows this bean to be mutated.
|
String |
toString()
Returns the name of the index.
|
clone, finalize, getClass, notify, notifyAll, wait, wait, waitextendedEnum, ofparse, parse, tryParse, tryParsepublic Tenor getTenor()
RateIndexpublic FloatingRateName getFloatingRateName()
FloatingRateIndex
For an Ibor index, the FloatingRateName does not include the tenor.
It can be used to find the other tenors available for this index.
getFloatingRateName in interface FloatingRategetFloatingRateName in interface FloatingRateIndexpublic ZonedDateTime calculateFixingDateTime(LocalDate fixingDate)
IborIndexThe fixing date is the date on which the index is to be observed. The fixing date-time is the specific date and time of the observation.
No error is thrown if the input date is not a valid fixing date.
calculateFixingDateTime in interface IborIndexfixingDate - the fixing datepublic LocalDate calculateEffectiveFromFixing(LocalDate fixingDate, ReferenceData refData)
IborIndexThe fixing date is the date on which the index is to be observed. The effective date is the date on which the implied deposit starts.
No error is thrown if the input date is not a valid fixing date. Instead, the fixing date is moved to the next valid fixing date and then processed.
calculateEffectiveFromFixing in interface IborIndexfixingDate - the fixing daterefData - the reference data, used to resolve the holiday calendarpublic LocalDate calculateMaturityFromFixing(LocalDate fixingDate, ReferenceData refData)
IborIndexThe fixing date is the date on which the index is to be observed. The maturity date is the date on which the implied deposit ends.
No error is thrown if the input date is not a valid fixing date. Instead, the fixing date is moved to the next valid fixing date and then processed.
calculateMaturityFromFixing in interface IborIndexfixingDate - the fixing daterefData - the reference data, used to resolve the holiday calendarpublic LocalDate calculateFixingFromEffective(LocalDate effectiveDate, ReferenceData refData)
IborIndexThe fixing date is the date on which the index is to be observed. The effective date is the date on which the implied deposit starts.
No error is thrown if the input date is not a valid effective date. Instead, the effective date is moved to the next valid effective date and then processed.
calculateFixingFromEffective in interface IborIndexeffectiveDate - the effective daterefData - the reference data, used to resolve the holiday calendarpublic LocalDate calculateMaturityFromEffective(LocalDate effectiveDate, ReferenceData refData)
IborIndexThe effective date is the date on which the implied deposit starts. The maturity date is the date on which the implied deposit ends.
No error is thrown if the input date is not a valid effective date. Instead, the effective date is moved to the next valid effective date and then processed.
calculateMaturityFromEffective in interface IborIndexeffectiveDate - the effective daterefData - the reference data, used to resolve the holiday calendarpublic Function<LocalDate,IborIndexObservation> resolve(ReferenceData refData)
IborIndex
This returns a Function that converts fixing dates to observations.
It binds the holiday calendar, looked up from the reference data, into the result.
As such, there is no need to pass the reference data in again.
This method is intended for use when looping to create multiple instances
of IborIndexObservation. Implementations of the method are intended
to optimize, avoiding repeated calls to resolve the holiday calendar
public String toString()
public static ImmutableIborIndex.Meta meta()
ImmutableIborIndex.public static ImmutableIborIndex.Builder builder()
public ImmutableIborIndex.Meta metaBean()
metaBean in interface org.joda.beans.Beanpublic String getName()
public Currency getCurrency()
getCurrency in interface FloatingRategetCurrency in interface FloatingRateIndexpublic boolean isActive()
Over time some indices become inactive and are no longer produced. If this occurs, this flag will be set to false.
isActive in interface FloatingRateIndexpublic HolidayCalendarId getFixingCalendar()
The fixing date is when the rate is determined.
getFixingCalendar in interface RateIndexpublic LocalTime getFixingTime()
The rate is fixed at the fixing time of the fixing date.
public ZoneId getFixingZone()
The time-zone of the fixing time.
public DaysAdjustment getFixingDateOffset()
The fixing date is the date on which the index is to be observed. In most cases, the fixing date is 0 or 2 days before the effective date. This data structure allows the complex rules of some indices to be represented.
getFixingDateOffset in interface IborIndexpublic DaysAdjustment getEffectiveDateOffset()
The effective date is the start date of the indexed deposit. In most cases, the effective date is 0 or 2 days after the fixing date. This data structure allows the complex rules of some indices to be represented.
getEffectiveDateOffset in interface IborIndexpublic TenorAdjustment getMaturityDateOffset()
The maturity date is the end date of the indexed deposit and is relative to the effective date. This data structure allows the complex rules of some indices to be represented.
getMaturityDateOffset in interface IborIndexpublic DayCount getDayCount()
getDayCount in interface FloatingRateIndexpublic DayCount getDefaultFixedLegDayCount()
A rate index is often paid against a fixed leg, such as in a vanilla Swap. The day count convention of the fixed leg often differs from that of the index, and the default is value is available here.
getDefaultFixedLegDayCount in interface FloatingRateIndexpublic ImmutableIborIndex.Builder toBuilder()
Copyright 2009-Present by OpenGamma Inc. and individual contributors
Apache v2 licensed
Additional documentation can be found at strata.opengamma.io.