public class Currency extends Object
| Modifier and Type | Field and Description |
|---|---|
static String |
CAD
Canadian dollar.
|
static String |
EUR
Euro.
|
static String |
USD
US dollar.
|
public static final String CAD
public static final String USD
public static final String EUR
public static double convert(double amount,
String from,
String to)
throws RuntimeException
RuntimeException - if the data is unavailable.amount - the amount to be converted.from - the currency from which to convert.to - the currency to which to convert.