## net.sf.saxon.trans
Class DecimalFormatManager

    java.lang.Object
      net.sf.saxon.trans.DecimalFormatManager

All Implemented Interfaces:
  java.io.Serializable

public class DecimalFormatManager
extends java.lang.Object
implements java.io.Serializable

DecimalFormatManager manages the collection of named and unnamed decimal formats

See Also:
  Serialized Form

Constructor Summary
`DecimalFormatManager()` create a DecimalFormatManager and initialise variables

Method Summary
`void` `fixupDefaultDefault()` Method called at the end of stylesheet compilation to fix up any format-number() calls to the "default default" decimal format
`java.text.DecimalFormatSymbols` `getDefaultDecimalFormat()` Get the default decimal-format.
`java.text.DecimalFormatSymbols` `getNamedDecimalFormat(java.lang.String uri, java.lang.String localName)` Get a named decimal-format registered using setNamedDecimalFormat
`void` `registerUsage(java.lang.String uri, java.lang.String localName, FormatNumber2 call)` Register a format-number() function call that uses a particular decimal format.
`void` `setDefaultDecimalFormat(java.text.DecimalFormatSymbols dfs, int precedence)` Register the default decimal-format.
`static void` `setDefaults(java.text.DecimalFormatSymbols d)` Set up the XSLT-defined default attributes in a DecimalFormatSymbols
`void` `setNamedDecimalFormat(java.lang.String uri, java.lang.String localName, java.text.DecimalFormatSymbols dfs, int precedence)` Set a named decimal format.

Methods inherited from class java.lang.Object
`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

Constructor Detail

### DecimalFormatManager

    public DecimalFormatManager()

  create a DecimalFormatManager and initialise variables

Method Detail

### setDefaults

    public static void setDefaults(java.text.DecimalFormatSymbols d)

  Set up the XSLT-defined default attributes in a DecimalFormatSymbols

### setDefaultDecimalFormat

    public void setDefaultDecimalFormat(java.text.DecimalFormatSymbols dfs,
                                        int precedence)
                                 throws StaticError

  Register the default decimal-format. Note that it is an error to register the same decimal-format twice, even with different precedence

  Throws:
    `StaticError`

### fixupDefaultDefault

    public void fixupDefaultDefault()
                             throws StaticError

  Method called at the end of stylesheet compilation to fix up any format-number() calls to the "default default" decimal format

  Throws:
    `StaticError`

### getDefaultDecimalFormat

    public java.text.DecimalFormatSymbols getDefaultDecimalFormat()

  Get the default decimal-format.

### setNamedDecimalFormat

    public void setNamedDecimalFormat(java.lang.String uri,
                                      java.lang.String localName,
                                      java.text.DecimalFormatSymbols dfs,
                                      int precedence)
                               throws StaticError

  Set a named decimal format. Note that it is an error to register the same decimal-format twice, unless hte values are equal, or unless there is another of higher precedence. This method assumes that decimal-formats are registered in order of decreasing precedence

  Parameters:
    `uri` - The URI of the name of the decimal format
    `localName` - The local part of the name of the decimal format
  Throws:
    `StaticError`

### registerUsage

    public void registerUsage(java.lang.String uri,
                              java.lang.String localName,
                              FormatNumber2 call)

  Register a format-number() function call that uses a particular decimal format. This allows early compile time resolution to a DecimalFormatSymbols object where possible, even in the case of a forwards reference

### getNamedDecimalFormat

    public java.text.DecimalFormatSymbols getNamedDecimalFormat(java.lang.String uri,
                                                                java.lang.String localName)

  Get a named decimal-format registered using setNamedDecimalFormat

  Parameters:
    `uri` - The URI of the name of the decimal format
    `localName` - The local part of the name of the decimal format
  Returns:
    the DecimalFormatSymbols object corresponding to the named locale, if any or null if not set.