Пример #1
0
 /**
  * Sets the default currency to use when creating fMoney objects
  * 
  * @param string  $iso_code  The ISO code (three letters, e.g. `'USD'`) for the new default currency
  * @return void
  */
 public static function setDefaultCurrency($iso_code)
 {
     if (!isset(self::$currencies[$iso_code])) {
         throw new fProgrammerException('The currency specified, %1$s, is not a valid currency. Must be one of: %2$s.', $iso_code, join(', ', array_keys(self::$currencies)));
     }
     self::$default_currency = $iso_code;
 }