| Modifier and Type | Field and Description |
|---|---|
| private final ConversionContext | |
| public static final String | |
| private final CurrencyUnit |
| Access | Constructor and Description |
|---|---|
| public |
| Modifier and Type | Method and Description |
|---|---|
| public MonetaryAmount | Returns: The converted amount, never null.The source amount amount)Implements javax. Method that converts the source |
| public ConversionContext | Returns: the targetConversionContext.Implements javax. Access the target |
| public CurrencyUnit | getCurrency()
Implements javax. Access the terminating |
| public abstract ExchangeRate | Returns: theExchangeRate to be used, or null, if this conversion
is not supported (will lead to a
CurrencyConversionException.Redeclares javax. Get the exchange rate type that this |
| protected NumberValue | Returns: the new rounding factor, never null.the amount, not null. amount, NumberValue the factor factor)Optionally rounds the factor to be used. |
| public String | |
| public abstract CurrencyConversion |
| conversionContext | back to summary |
|---|---|
| private final ConversionContext conversionContext | |
| KEY_SCALE | back to summary |
|---|---|
| public static final String KEY_SCALE | |
| termCurrency | back to summary |
|---|---|
| private final CurrencyUnit termCurrency | |
| AbstractCurrencyConversion | back to summary |
|---|---|
| public AbstractCurrencyConversion(CurrencyUnit termCurrency, ConversionContext conversionContext) | |
| apply | back to summary |
|---|---|
| public MonetaryAmount apply(MonetaryAmount amount) Implements javax. Method that converts the source
| |
| getContext | back to summary |
|---|---|
| public ConversionContext getContext() Implements javax. Access the target
| |
| getCurrency | back to summary |
|---|---|
| public CurrencyUnit getCurrency() Implements javax. Access the terminating
| |
| getExchangeRate | back to summary |
|---|---|
| public abstract ExchangeRate getExchangeRate(MonetaryAmount sourceAmount) Redeclares javax. Get the exchange rate type that this
| |
| roundFactor | back to summary |
|---|---|
| protected NumberValue roundFactor(MonetaryAmount amount, NumberValue factor) Optionally rounds the factor to be used. By default this method will only round
as much as it is needed, so the factor can be handled by the target amount instance based on its
numeric capabilities. Rounding is applied only if
| |
| toString | back to summary |
|---|---|
| public String toString() Overrides java. Doc from java. Returns a string representation of the object.
Satisfying this method's contract implies a non-
| |
| with | back to summary |
|---|---|
| public abstract CurrencyConversion with(ConversionContext conversionContext) | |