Tuan-Anh Tran

Java 9 is coming with money API

Posted on August 27, 2014  •  1 minutes  • 58 words

Java provides you two exchange providers which are ECB (European Central Bank) and IMF (International Monetary Fund). You also can write our own class implementing ExchangeRateProvider interface. The biggest problem here is the data though, not the implementation . If you work for a bank, problem is solved.

ExchangeRateProvider imfRateProvider = MonetaryConversions
                          .getExchangeRateProvider("IMF"); 
ExchangeRateProvider ecbRateProvider = MonetaryConversions 
                          .getExchangeRateProvider("ECB"); 
Follow me

Here's where I hang out in social media