Class FixedCouponBondTrade.Builder

    • Method Detail

      • get

        public java.lang.Object get​(java.lang.String propertyName)
        Specified by:
        get in interface org.joda.beans.BeanBuilder<FixedCouponBondTrade>
        Overrides:
        get in class org.joda.beans.impl.direct.DirectFieldsBeanBuilder<FixedCouponBondTrade>
      • product

        public FixedCouponBondTrade.Builder product​(FixedCouponBond product)
        Sets the bond that was traded.

        The product captures the contracted financial details of the trade.

        Parameters:
        product - the new value, not null
        Returns:
        this, for chaining, not null
      • quantity

        public FixedCouponBondTrade.Builder quantity​(double quantity)
        Sets the quantity that was traded.

        This will be positive if buying and negative if selling.

        Parameters:
        quantity - the new value
        Returns:
        this, for chaining, not null
      • price

        public FixedCouponBondTrade.Builder price​(double price)
        Sets the clean price at which the bond was traded, in decimal form.

        The "clean" price excludes any accrued interest.

        Strata uses decimal prices for bonds in the trade model, pricers and market data. For example, a price of 99.32% is represented in Strata by 0.9932.

        Parameters:
        price - the new value
        Returns:
        this, for chaining, not null
      • toString

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