Top Description Fields Constructors Methods
org.javamoney.moneta.convert

public final Enum ExchangeRateType

extends Enum<ExchangeRateType>
implements ExchangeRateProviderSupplier
Class Inheritance
All Implemented Interfaces
javax.money.convert.ExchangeRateProviderSupplier
Imports
javax.money.convert.ExchangeRateProviderSupplier

This enum contains all implementations by Moneta. Using this enum will easier to choose an available implementation.

ExchangeRateProvider provider = MonetaryConversions.getExchangeRateProvider(ExchangeRateType.ECB);
Authors
otaviojava, Werner Keil
Since
1.0.1

Field Summary

Modifier and TypeField and Description
private final String
public static final ExchangeRateType
ECB

Exchange rate to the European Central Bank.

public static final ExchangeRateType
ECB_HIST

Uses the ECBHistoricRateProvider implementation.

public static final ExchangeRateType
ECB_HIST90

Exchange rate to European Central Bank (last 90 days).

public static final ExchangeRateType
IDENTITY

Uses the IdentityRateProvider implementation.

public static final ExchangeRateType
IMF

Exchange rate to the International Monetary Fund.

public static final ExchangeRateType
IMF_HIST

Exchange rate to the International Monetary Fund from historic.

private final String

Constructor Summary

AccessConstructor and Description
private
ExchangeRateType(String type, String description)

Method Summary

Modifier and TypeMethod and Description
public String
get()

Implements javax.money.convert.ExchangeRateProviderSupplier.get.

Get the provider name.

public String
public static ExchangeRateType
public static ExchangeRateType[]
Inherited from java.lang.Enum:
clonecompareTodescribeConstableequalsfinalizegetDeclaringClasshashCodenameordinaltoStringvalueOf

Field Detail

descriptionback to summary
private final String description
ECBback to summary
public static final ExchangeRateType ECB

Exchange rate to the European Central Bank. Uses the ECBCurrentRateProvider implementation.

ECB_HISTback to summary
public static final ExchangeRateType ECB_HIST

Uses the ECBHistoricRateProvider implementation.

ECB_HIST90back to summary
public static final ExchangeRateType ECB_HIST90

Exchange rate to European Central Bank (last 90 days). Uses the ECBHistoric90RateProvider implementation.

IDENTITYback to summary
public static final ExchangeRateType IDENTITY

Uses the IdentityRateProvider implementation.

IMFback to summary
public static final ExchangeRateType IMF

Exchange rate to the International Monetary Fund. Uses the IMFRateProvider implementation.

IMF_HISTback to summary
public static final ExchangeRateType IMF_HIST

Exchange rate to the International Monetary Fund from historic. Uses the IMFHistoricRateProvider implementation.

typeback to summary
private final String type

Constructor Detail

ExchangeRateTypeback to summary
private ExchangeRateType(String type, String description)

Method Detail

getback to summary
public String get()

Implements javax.money.convert.ExchangeRateProviderSupplier.get.

Doc from javax.money.convert.ExchangeRateProviderSupplier.get.

Get the provider name. This signature equals to the signature of java.util.function.Supplier in Java 8.

Annotations
@Override
getDescriptionback to summary
public String getDescription()
valueOfback to summary
public static ExchangeRateType valueOf(String name)
valuesback to summary
public static ExchangeRateType[] values()