Class EtdFutureTrade.Builder

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

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

      • get

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

        public EtdFutureTrade.Builder set​(org.joda.beans.MetaProperty<?> property,
                                          java.lang.Object value)
        Specified by:
        set in interface org.joda.beans.BeanBuilder<EtdFutureTrade>
        Overrides:
        set in class org.joda.beans.impl.direct.DirectFieldsBeanBuilder<EtdFutureTrade>
      • info

        public EtdFutureTrade.Builder info​(TradeInfo info)
        Sets the additional trade information, defaulted to an empty instance.

        This allows additional information to be attached to the trade.

        Parameters:
        info - the new value, not null
        Returns:
        this, for chaining, not null
      • security

        public EtdFutureTrade.Builder security​(EtdFutureSecurity security)
        Sets the security that was traded.
        Parameters:
        security - the new value, not null
        Returns:
        this, for chaining, not null
      • quantity

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

        This is the number of contracts that were traded. This will be positive if buying and negative if selling.

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

        public EtdFutureTrade.Builder price​(double price)
        Sets the price that was traded, in decimal form.

        This is the price agreed when the trade occurred.

        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<EtdFutureTrade>