Class FxVanillaOption.Builder
- java.lang.Object
-
- org.joda.beans.impl.direct.DirectFieldsBeanBuilder<FxVanillaOption>
-
- com.opengamma.strata.product.fxopt.FxVanillaOption.Builder
-
- All Implemented Interfaces:
org.joda.beans.BeanBuilder<FxVanillaOption>
- Enclosing class:
- FxVanillaOption
public static final class FxVanillaOption.Builder extends org.joda.beans.impl.direct.DirectFieldsBeanBuilder<FxVanillaOption>
The bean-builder forFxVanillaOption
.
-
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description FxVanillaOption
build()
FxVanillaOption.Builder
expiryDate(LocalDate expiryDate)
Sets the expiry date of the option.FxVanillaOption.Builder
expiryTime(LocalTime expiryTime)
Sets the expiry time of the option.FxVanillaOption.Builder
expiryZone(ZoneId expiryZone)
Sets the time-zone of the expiry time.Object
get(String propertyName)
FxVanillaOption.Builder
longShort(LongShort longShort)
Sets whether the option is long or short.FxVanillaOption.Builder
set(String propertyName, Object newValue)
FxVanillaOption.Builder
set(org.joda.beans.MetaProperty<?> property, Object value)
String
toString()
FxVanillaOption.Builder
underlying(FxSingle underlying)
Sets the underlying foreign exchange transaction.
-
-
-
Method Detail
-
get
public Object get(String propertyName)
- Specified by:
get
in interfaceorg.joda.beans.BeanBuilder<FxVanillaOption>
- Overrides:
get
in classorg.joda.beans.impl.direct.DirectFieldsBeanBuilder<FxVanillaOption>
-
set
public FxVanillaOption.Builder set(String propertyName, Object newValue)
-
set
public FxVanillaOption.Builder set(org.joda.beans.MetaProperty<?> property, Object value)
- Specified by:
set
in interfaceorg.joda.beans.BeanBuilder<FxVanillaOption>
- Overrides:
set
in classorg.joda.beans.impl.direct.DirectFieldsBeanBuilder<FxVanillaOption>
-
build
public FxVanillaOption build()
-
longShort
public FxVanillaOption.Builder longShort(LongShort longShort)
Sets whether the option is long or short.At expiry, the long party will have the option to enter in this transaction; the short party will, at the option of the long party, potentially enter into the inverse transaction.
- Parameters:
longShort
- the new value, not null- Returns:
- this, for chaining, not null
-
expiryDate
public FxVanillaOption.Builder expiryDate(LocalDate expiryDate)
Sets the expiry date of the option.The option is European, and can only be exercised on the expiry date.
- Parameters:
expiryDate
- the new value, not null- Returns:
- this, for chaining, not null
-
expiryTime
public FxVanillaOption.Builder expiryTime(LocalTime expiryTime)
Sets the expiry time of the option.The expiry time is related to the expiry date and time-zone.
- Parameters:
expiryTime
- the new value, not null- Returns:
- this, for chaining, not null
-
expiryZone
public FxVanillaOption.Builder expiryZone(ZoneId expiryZone)
Sets the time-zone of the expiry time.The expiry time-zone is related to the expiry date and time.
- Parameters:
expiryZone
- the new value, not null- Returns:
- this, for chaining, not null
-
underlying
public FxVanillaOption.Builder underlying(FxSingle underlying)
Sets the underlying foreign exchange transaction.At expiry, if the option is in the money, this foreign exchange will occur.
- Parameters:
underlying
- the new value, not null- Returns:
- this, for chaining, not null
-
toString
public String toString()
- Overrides:
toString
in classorg.joda.beans.impl.direct.DirectFieldsBeanBuilder<FxVanillaOption>
-
-