Class ImmutableFxSwapConvention.Builder
- java.lang.Object
-
- org.joda.beans.impl.direct.DirectFieldsBeanBuilder<ImmutableFxSwapConvention>
-
- com.opengamma.strata.product.fx.type.ImmutableFxSwapConvention.Builder
-
- All Implemented Interfaces:
org.joda.beans.BeanBuilder<ImmutableFxSwapConvention>
- Enclosing class:
- ImmutableFxSwapConvention
public static final class ImmutableFxSwapConvention.Builder extends org.joda.beans.impl.direct.DirectFieldsBeanBuilder<ImmutableFxSwapConvention>
The bean-builder forImmutableFxSwapConvention
.
-
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description ImmutableFxSwapConvention
build()
ImmutableFxSwapConvention.Builder
businessDayAdjustment(BusinessDayAdjustment businessDayAdjustment)
Sets the business day adjustment to apply to the start and end date, optional with defaulting getter.ImmutableFxSwapConvention.Builder
currencyPair(CurrencyPair currencyPair)
Sets the currency pair associated with the convention.Object
get(String propertyName)
ImmutableFxSwapConvention.Builder
name(String name)
Sets the convention name, such as 'EUR/USD', optional with defaulting getter.ImmutableFxSwapConvention.Builder
set(String propertyName, Object newValue)
ImmutableFxSwapConvention.Builder
set(org.joda.beans.MetaProperty<?> property, Object value)
ImmutableFxSwapConvention.Builder
spotDateOffset(DaysAdjustment spotDateOffset)
Sets the offset of the spot value date from the trade date.String
toString()
-
-
-
Method Detail
-
get
public Object get(String propertyName)
- Specified by:
get
in interfaceorg.joda.beans.BeanBuilder<ImmutableFxSwapConvention>
- Overrides:
get
in classorg.joda.beans.impl.direct.DirectFieldsBeanBuilder<ImmutableFxSwapConvention>
-
set
public ImmutableFxSwapConvention.Builder set(String propertyName, Object newValue)
-
set
public ImmutableFxSwapConvention.Builder set(org.joda.beans.MetaProperty<?> property, Object value)
- Specified by:
set
in interfaceorg.joda.beans.BeanBuilder<ImmutableFxSwapConvention>
- Overrides:
set
in classorg.joda.beans.impl.direct.DirectFieldsBeanBuilder<ImmutableFxSwapConvention>
-
build
public ImmutableFxSwapConvention build()
-
currencyPair
public ImmutableFxSwapConvention.Builder currencyPair(CurrencyPair currencyPair)
Sets the currency pair associated with the convention.- Parameters:
currencyPair
- the new value, not null- Returns:
- this, for chaining, not null
-
name
public ImmutableFxSwapConvention.Builder name(String name)
Sets the convention name, such as 'EUR/USD', optional with defaulting getter.This will default to the name of the currency pair if not specified.
- Parameters:
name
- the new value- Returns:
- this, for chaining, not null
-
spotDateOffset
public ImmutableFxSwapConvention.Builder spotDateOffset(DaysAdjustment spotDateOffset)
Sets the offset of the spot value date from the trade date.The offset is applied to the trade date and is typically plus 2 business days in the joint calendar of the two currencies. The start and end date of the FX swap are relative to the spot date.
- Parameters:
spotDateOffset
- the new value, not null- Returns:
- this, for chaining, not null
-
businessDayAdjustment
public ImmutableFxSwapConvention.Builder businessDayAdjustment(BusinessDayAdjustment businessDayAdjustment)
Sets the business day adjustment to apply to the start and end date, optional with defaulting getter.The start and end date are typically defined as valid business days and thus do not need to be adjusted. If this optional property is present, then the start and end date will be adjusted as defined here.
This will default to 'ModifiedFollowing' using the spot date offset calendar if not specified.
- Parameters:
businessDayAdjustment
- the new value- Returns:
- this, for chaining, not null
-
toString
public String toString()
- Overrides:
toString
in classorg.joda.beans.impl.direct.DirectFieldsBeanBuilder<ImmutableFxSwapConvention>
-
-