Class ResolvedIborFutureOptionTrade.Builder
- java.lang.Object
-
- org.joda.beans.impl.direct.DirectFieldsBeanBuilder<ResolvedIborFutureOptionTrade>
-
- com.opengamma.strata.product.index.ResolvedIborFutureOptionTrade.Builder
-
- All Implemented Interfaces:
org.joda.beans.BeanBuilder<ResolvedIborFutureOptionTrade>
- Enclosing class:
- ResolvedIborFutureOptionTrade
public static final class ResolvedIborFutureOptionTrade.Builder extends org.joda.beans.impl.direct.DirectFieldsBeanBuilder<ResolvedIborFutureOptionTrade>
The bean-builder forResolvedIborFutureOptionTrade
.
-
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description ResolvedIborFutureOptionTrade
build()
Object
get(String propertyName)
ResolvedIborFutureOptionTrade.Builder
info(PortfolioItemInfo info)
Sets the additional information, defaulted to an empty instance.ResolvedIborFutureOptionTrade.Builder
product(ResolvedIborFutureOption product)
Sets the option that was traded.ResolvedIborFutureOptionTrade.Builder
quantity(double quantity)
Sets the quantity that was traded.ResolvedIborFutureOptionTrade.Builder
set(String propertyName, Object newValue)
ResolvedIborFutureOptionTrade.Builder
set(org.joda.beans.MetaProperty<?> property, Object value)
String
toString()
ResolvedIborFutureOptionTrade.Builder
tradedPrice(TradedPrice tradedPrice)
Sets the price that was traded, together with the trade date, optional.
-
-
-
Method Detail
-
get
public Object get(String propertyName)
- Specified by:
get
in interfaceorg.joda.beans.BeanBuilder<ResolvedIborFutureOptionTrade>
- Overrides:
get
in classorg.joda.beans.impl.direct.DirectFieldsBeanBuilder<ResolvedIborFutureOptionTrade>
-
set
public ResolvedIborFutureOptionTrade.Builder set(String propertyName, Object newValue)
-
set
public ResolvedIborFutureOptionTrade.Builder set(org.joda.beans.MetaProperty<?> property, Object value)
- Specified by:
set
in interfaceorg.joda.beans.BeanBuilder<ResolvedIborFutureOptionTrade>
- Overrides:
set
in classorg.joda.beans.impl.direct.DirectFieldsBeanBuilder<ResolvedIborFutureOptionTrade>
-
build
public ResolvedIborFutureOptionTrade build()
-
info
public ResolvedIborFutureOptionTrade.Builder info(PortfolioItemInfo info)
Sets the additional information, defaulted to an empty instance.This allows additional information to be attached.
- Parameters:
info
- the new value, not null- Returns:
- this, for chaining, not null
-
product
public ResolvedIborFutureOptionTrade.Builder product(ResolvedIborFutureOption product)
Sets the option 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 ResolvedIborFutureOptionTrade.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
-
tradedPrice
public ResolvedIborFutureOptionTrade.Builder tradedPrice(TradedPrice tradedPrice)
Sets the price that was traded, together with the trade date, optional.This is the price agreed when the trade occurred, in decimal form. Strata uses decimal prices for Ibor future options in the trade model, pricers and market data. The decimal price is based on the decimal rate equivalent to the percentage. For example, an option price of 0.2 is related to a futures price of 99.32 that implies an interest rate of 0.68%. Strata represents the price of the future as 0.9932 and thus represents the price of the option as 0.002.
This is optional to allow the class to be used to price both trades and positions. When the instance represents a trade, the traded price should be present. When the instance represents a position, the traded price should be empty.
- Parameters:
tradedPrice
- the new value- Returns:
- this, for chaining, not null
-
toString
public String toString()
- Overrides:
toString
in classorg.joda.beans.impl.direct.DirectFieldsBeanBuilder<ResolvedIborFutureOptionTrade>
-
-