Class IborFixingDeposit.Builder

  • All Implemented Interfaces:
    org.joda.beans.BeanBuilder<IborFixingDeposit>
    Enclosing class:
    IborFixingDeposit

    public static final class IborFixingDeposit.Builder
    extends org.joda.beans.impl.direct.DirectFieldsBeanBuilder<IborFixingDeposit>
    The bean-builder for IborFixingDeposit.
    • Method Detail

      • buySell

        public IborFixingDeposit.Builder buySell​(BuySell buySell)
        Sets whether the Ibor fixing deposit is 'Buy' or 'Sell'.

        A value of 'Buy' implies that the floating rate is paid to the counterparty, with the fixed rate being received. A value of 'Sell' implies that the floating rate is received from the counterparty, with the fixed rate being paid.

        Parameters:
        buySell - the new value, not null
        Returns:
        this, for chaining, not null
      • currency

        public IborFixingDeposit.Builder currency​(Currency currency)
        Sets the primary currency, defaulted to the currency of the index.

        This is the currency of the deposit and the currency that payment is made in. The data model permits this currency to differ from that of the index, however the two are typically the same.

        When building, this will default to the currency of the index if not specified.

        Parameters:
        currency - the new value, not null
        Returns:
        this, for chaining, not null
      • notional

        public IborFixingDeposit.Builder notional​(double notional)
        Sets the notional amount.

        The notional expressed here must be non-negative. The currency of the notional is specified by currency.

        Parameters:
        notional - the new value
        Returns:
        this, for chaining, not null
      • startDate

        public IborFixingDeposit.Builder startDate​(LocalDate startDate)
        Sets the start date of the deposit.

        Interest accrues from this date. This date is typically set to be a valid business day. Optionally, the businessDayAdjustment property may be set to provide a rule for adjustment.

        Parameters:
        startDate - the new value, not null
        Returns:
        this, for chaining, not null
      • endDate

        public IborFixingDeposit.Builder endDate​(LocalDate endDate)
        Sets the end date of the deposit.

        Interest accrues until this date. This date is typically set to be a valid business day. Optionally, the businessDayAdjustment property may be set to provide a rule for adjustment. This date must be after the start date.

        Parameters:
        endDate - the new value, not null
        Returns:
        this, for chaining, not null
      • businessDayAdjustment

        public IborFixingDeposit.Builder businessDayAdjustment​(BusinessDayAdjustment businessDayAdjustment)
        Sets the business day adjustment to apply to the start and end date, optional.

        The start and end date are typically defined as valid business days and thus do not need to be adjusted. If this optional property is present, then the start and end date will be adjusted as defined here.

        Parameters:
        businessDayAdjustment - the new value
        Returns:
        this, for chaining, not null
      • index

        public IborFixingDeposit.Builder index​(IborIndex index)
        Sets the Ibor index.

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

        See buySell to determine whether this rate is paid or received.

        Parameters:
        index - the new value, not null
        Returns:
        this, for chaining, not null
      • fixingDateOffset

        public IborFixingDeposit.Builder fixingDateOffset​(DaysAdjustment fixingDateOffset)
        Sets the offset of the fixing date from the start date.

        The offset is applied to the start date and is typically minus 2 business days. The data model permits the offset to differ from that of the index, however the two are typically the same.

        When building, this will default to the fixing date offset of the index if not specified.

        Parameters:
        fixingDateOffset - the new value, not null
        Returns:
        this, for chaining, not null
      • dayCount

        public IborFixingDeposit.Builder dayCount​(DayCount dayCount)
        Sets the day count convention applicable, defaulted to the day count of the index.

        This is used to convert dates to a numerical value. The data model permits the day count to differ from that of the index, however the two are typically the same.

        When building, this will default to the day count of the index if not specified.

        Parameters:
        dayCount - the new value, not null
        Returns:
        this, for chaining, not null
      • fixedRate

        public IborFixingDeposit.Builder fixedRate​(double fixedRate)
        Sets the fixed interest rate to be paid. A 5% rate will be expressed as 0.05.
        Parameters:
        fixedRate - the new value
        Returns:
        this, for chaining, not null
      • toString

        public String toString()
        Overrides:
        toString in class org.joda.beans.impl.direct.DirectFieldsBeanBuilder<IborFixingDeposit>