Class IborIndexObservation

  • All Implemented Interfaces:
    IndexObservation, java.io.Serializable, Bean, ImmutableBean

    public final class IborIndexObservation
    extends java.lang.Object
    implements IndexObservation, ImmutableBean, java.io.Serializable
    Defines the observation of a rate of interest from a single Ibor index.

    An interest rate determined directly from an Ibor index. For example, a rate determined from 'GBP-LIBOR-3M' on a single fixing date.

    See Also:
    Serialized Form
    • Method Detail

      • of

        public static IborIndexObservation of​(IborIndex index,
                                              java.time.LocalDate fixingDate,
                                              ReferenceData refData)
        Creates an instance from an index and fixing date.

        The reference data is used to find the maturity date from the fixing date.

        Parameters:
        index - the index
        fixingDate - the fixing date
        refData - the reference data to use when resolving holiday calendars
        Returns:
        the rate observation
      • getCurrency

        public Currency getCurrency()
        Gets the currency of the Ibor index.
        Returns:
        the currency of the index
      • meta

        public static IborIndexObservation.Meta meta()
        The meta-bean for IborIndexObservation.
        Returns:
        the meta-bean, not null
      • getIndex

        public IborIndex getIndex()
        Gets the Ibor index.

        The rate to be paid is based on this index. It will be a well known market index such as 'GBP-LIBOR-3M'.

        Specified by:
        getIndex in interface IndexObservation
        Returns:
        the value of the property, not null
      • getFixingDate

        public java.time.LocalDate getFixingDate()
        Gets the date of the index fixing.

        This is an adjusted date with any business day rule applied. Valid business days are defined by RateIndex.getFixingCalendar().

        Returns:
        the value of the property, not null
      • getEffectiveDate

        public java.time.LocalDate getEffectiveDate()
        Gets the effective date of the investment implied by the fixing date.

        This is an adjusted date with any business day rule applied. This must be equal to IborIndex.calculateEffectiveFromFixing(LocalDate, ReferenceData).

        Returns:
        the value of the property, not null
      • getYearFraction

        public double getYearFraction()
        Gets the year fraction of the investment implied by the fixing date.

        This is calculated using the day count of the index. It represents the fraction of the year between the effective date and the maturity date. Typically the value will be close to 1 for one year and close to 0.5 for six months.

        Returns:
        the value of the property, not null
      • equals

        public boolean equals​(java.lang.Object obj)
        Overrides:
        equals in class java.lang.Object
      • hashCode

        public int hashCode()
        Overrides:
        hashCode in class java.lang.Object
      • toString

        public java.lang.String toString()
        Overrides:
        toString in class java.lang.Object