Interface SwapIndex

  • All Superinterfaces:
    Index, Named
    All Known Implementing Classes:

    public interface SwapIndex
    extends Index, Named
    A swap index.

    Swap rates for different currencies are published by several providers. The indices can be related to IBOR-linked swaps or Overnight-linked swaps. Ref:

    The most common implementations are provided in SwapIndices.

    All implementations of this interface must be immutable and thread-safe.

    • Method Detail

      • of

        static SwapIndex of​(String uniqueName)
        Obtains an instance from the specified unique name.
        uniqueName - the unique name
        the index
        IllegalArgumentException - if the name is not known
      • extendedEnum

        static ExtendedEnum<SwapIndex> extendedEnum()
        Gets the extended enum helper.

        This helper allows instances of the index to be looked up. It also provides the complete set of available instances.

        the extended enum helper
      • isActive

        boolean isActive()
        Gets whether the index is active.

        Over time some indices become inactive and are no longer produced. If this occurs, this method will return false.

        true if the index is active, false if inactive
      • getFixingTime

        LocalTime getFixingTime()
        Gets the fixing time of the index.

        The fixing time is related to the fixing date and time-zone.

        the fixing time
      • getFixingZone

        ZoneId getFixingZone()
        Gets the time-zone of the fixing time.

        The fixing time-zone is related to the fixing date and time.

        the time-zone of the fixing time
      • getTemplate

        FixedFloatSwapTemplate getTemplate()
        Gets the template for creating Fixed-Float swap.
        the template
      • calculateFixingDateTime

        default ZonedDateTime calculateFixingDateTime​(LocalDate fixingDate)
        Calculates the fixing date-time from the fixing date.

        The fixing date is the date on which the index is to be observed. The result combines the date with the time and zone stored in the index.

        No error is thrown if the input date is not a valid fixing date.

        fixingDate - the fixing date
        the fixing date-time
      • getName

        String getName()
        Gets the name that uniquely identifies this index.

        This name is used in serialization and can be parsed using of(String).

        Specified by:
        getName in interface Index
        Specified by:
        getName in interface Named
        the unique name