public static final class GenericSecurityTrade.Builder extends org.joda.beans.impl.direct.DirectFieldsBeanBuilder<GenericSecurityTrade>
GenericSecurityTrade.| Modifier and Type | Method and Description |
|---|---|
GenericSecurityTrade |
build() |
Object |
get(String propertyName) |
GenericSecurityTrade.Builder |
info(TradeInfo info)
Sets the additional trade information, defaulted to an empty instance.
|
GenericSecurityTrade.Builder |
price(double price)
Sets the price that was traded, in decimal form.
|
GenericSecurityTrade.Builder |
quantity(double quantity)
Sets the quantity that was traded.
|
GenericSecurityTrade.Builder |
security(GenericSecurity security)
Sets the security that was traded.
|
GenericSecurityTrade.Builder |
set(org.joda.beans.MetaProperty<?> property,
Object value) |
GenericSecurityTrade.Builder |
set(String propertyName,
Object newValue) |
String |
toString() |
public Object get(String propertyName)
get in interface org.joda.beans.BeanBuilder<GenericSecurityTrade>get in class org.joda.beans.impl.direct.DirectFieldsBeanBuilder<GenericSecurityTrade>public GenericSecurityTrade.Builder set(String propertyName, Object newValue)
public GenericSecurityTrade.Builder set(org.joda.beans.MetaProperty<?> property, Object value)
set in interface org.joda.beans.BeanBuilder<GenericSecurityTrade>set in class org.joda.beans.impl.direct.DirectFieldsBeanBuilder<GenericSecurityTrade>public GenericSecurityTrade build()
public GenericSecurityTrade.Builder info(TradeInfo info)
This allows additional information to be attached to the trade.
info - the new value, not nullpublic GenericSecurityTrade.Builder security(GenericSecurity security)
security - the new value, not nullpublic GenericSecurityTrade.Builder quantity(double quantity)
This is the number of contracts that were traded. This will be positive if buying and negative if selling.
quantity - the new valuepublic GenericSecurityTrade.Builder price(double price)
This is the price agreed when the trade occurred.
price - the new valuepublic String toString()
toString in class org.joda.beans.impl.direct.DirectFieldsBeanBuilder<GenericSecurityTrade>Copyright 2009-Present by OpenGamma Inc. and individual contributors
Apache v2 licensed
Additional documentation can be found at strata.opengamma.io.