Class SwapLegAmount.Builder
- java.lang.Object
-
- org.joda.beans.impl.direct.DirectFieldsBeanBuilder<SwapLegAmount>
-
- com.opengamma.strata.market.amount.SwapLegAmount.Builder
-
- All Implemented Interfaces:
org.joda.beans.BeanBuilder<SwapLegAmount>
- Enclosing class:
- SwapLegAmount
public static final class SwapLegAmount.Builder extends org.joda.beans.impl.direct.DirectFieldsBeanBuilder<SwapLegAmount>
The bean-builder forSwapLegAmount.
-
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description SwapLegAmount.Builderamount(CurrencyAmount amount)Sets the amount associated with the leg.SwapLegAmountbuild()SwapLegAmount.Buildercurrency(Currency currency)Sets the currency of the leg.Objectget(String propertyName)SwapLegAmount.BuilderpayReceive(PayReceive payReceive)Sets whether the leg is pay or receive.SwapLegAmount.Builderset(String propertyName, Object newValue)SwapLegAmount.Builderset(org.joda.beans.MetaProperty<?> property, Object value)StringtoString()SwapLegAmount.Buildertype(SwapLegType type)Sets the type of the leg, such as Fixed or Ibor.
-
-
-
Method Detail
-
get
public Object get(String propertyName)
- Specified by:
getin interfaceorg.joda.beans.BeanBuilder<SwapLegAmount>- Overrides:
getin classorg.joda.beans.impl.direct.DirectFieldsBeanBuilder<SwapLegAmount>
-
set
public SwapLegAmount.Builder set(String propertyName, Object newValue)
-
set
public SwapLegAmount.Builder set(org.joda.beans.MetaProperty<?> property, Object value)
- Specified by:
setin interfaceorg.joda.beans.BeanBuilder<SwapLegAmount>- Overrides:
setin classorg.joda.beans.impl.direct.DirectFieldsBeanBuilder<SwapLegAmount>
-
build
public SwapLegAmount build()
-
amount
public SwapLegAmount.Builder amount(CurrencyAmount amount)
Sets the amount associated with the leg. The meaning associated with this amount is implied by the context. This amount may have been currency converted.- Parameters:
amount- the new value, not null- Returns:
- this, for chaining, not null
-
payReceive
public SwapLegAmount.Builder payReceive(PayReceive payReceive)
Sets whether the leg is pay or receive.- Parameters:
payReceive- the new value, not null- Returns:
- this, for chaining, not null
-
type
public SwapLegAmount.Builder type(SwapLegType type)
Sets the type of the leg, such as Fixed or Ibor.- Parameters:
type- the new value, not null- Returns:
- this, for chaining, not null
-
currency
public SwapLegAmount.Builder currency(Currency currency)
Sets the currency of the leg. This is not be affected by any currency conversion applied to the amount.- Parameters:
currency- the new value, not null- Returns:
- this, for chaining, not null
-
toString
public String toString()
- Overrides:
toStringin classorg.joda.beans.impl.direct.DirectFieldsBeanBuilder<SwapLegAmount>
-
-