jgnash.engine
Class DefaultCurrencies

java.lang.Object
  extended by jgnash.engine.DefaultCurrencies

public class DefaultCurrencies
extends java.lang.Object

Static methods for currency generation and discovery These are known to not show up because Java 1.4.2 and older does not have a default NumberFormat defined for the currency:
"SGD"
"MYR"

Version:
$Id$
Author:
Craig Cavanaugh

Constructor Summary
private DefaultCurrencies()
          Private Constructor, use static methods only
 
Method Summary
static CurrencyNode buildCustomNode(java.lang.String ISOCode)
          Creates a custom CurrencyNode given an ISO code.
static CurrencyNode buildNode(java.util.Locale locale)
          Creates a valid CurrencyNode given a locale
static java.util.Set<CurrencyNode> generateCurrencies()
          Generates an array of default currency nodes that Java knows about.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

DefaultCurrencies

private DefaultCurrencies()
Private Constructor, use static methods only

Method Detail

generateCurrencies

public static java.util.Set<CurrencyNode> generateCurrencies()
Generates an array of default currency nodes that Java knows about.

Returns:
An array of default CurrencyNodes

buildCustomNode

public static CurrencyNode buildCustomNode(java.lang.String ISOCode)
Creates a custom CurrencyNode given an ISO code. If the ISO code is not valid, then a node will be generated using the supplied code. The locale is assumed to be the default locale.

Parameters:
ISOCode - The custom currency to generate
Returns:
The custom CurrencyNode

buildNode

public static CurrencyNode buildNode(java.util.Locale locale)
Creates a valid CurrencyNode given a locale

Parameters:
locale - Locale to create a CurrencyNode for
Returns:
The new CurrencyNode