Beispiel #1
0
 /**
  * Returns the specified physical currency's value.
  *
  * @param currency
  * @throws NoCurrencyException
  * @return Currency value
  */
 public static double getPhysicalCurrencyValue(String currency) {
   if (Currency.physicalExists(currency)) {
     return Currency.getPhysicalValue(currency);
   } else {
     throw new NoCurrencyException(
         "MCCom: public static double getPhysicalCurrencyValue(String currency)", "currency");
   }
 }
Beispiel #2
0
 /**
  * Gets the ID of the specified currency.
  *
  * @param currency
  * @return The ID of the specified currency.
  */
 public static String getCurrencyId(String currency) {
   if (Currency.physicalExists(currency)) {
     return Currency.getId(currency);
   } else {
     throw new NoCurrencyException(
         "MCCom: public static String getCurrencyId(String currency)", "currency");
   }
 }
Beispiel #3
0
 /**
  * Returns true if the specified physical currency exists.
  *
  * @param currency
  * @return True is specified physical currency exists.
  */
 public static boolean physicalCurrencyExists(String currency) {
   return Currency.physicalExists(currency);
 }