org.springframework.binding.format
Interface FormatterFactory

All Known Implementing Classes:
AbstractFormatterFactory, SimpleFormatterFactory

public interface FormatterFactory

Source for shared and commonly used Formatters.

Formatters are typically not thread safe as Format objects aren't thread safe: so implementations of this service should take care to synchronize them as neccessary.

Author:
Keith Donald
See Also:
Format

Method Summary
 Formatter getCurrencyFormatter()
          Returns a currency number formatter.
 Formatter getDateFormatter()
          Returns the default date format for the current locale.
 Formatter getDateFormatter(java.lang.String encodedFormat)
          Returns a date formatter for the encoded date format.
 Formatter getDateFormatter(Style style)
          Returns the date format with the specified style for the current locale.
 Formatter getDateTimeFormatter()
          Returns the default date/time format for the current locale.
 Formatter getDateTimeFormatter(Style dateStyle, Style timeStyle)
          Returns the date format with the specified styles for the current locale.
 Formatter getNumberFormatter(java.lang.Class numberClass)
          Returns a number formatter for the specified class.
 Formatter getPercentFormatter()
          Returns a percent number formatter.
 Formatter getTimeFormatter()
          Returns the default time format for the current locale.
 Formatter getTimeFormatter(Style style)
          Returns the time format with the specified style for the current locale.
 

Method Detail

getDateFormatter

Formatter getDateFormatter(java.lang.String encodedFormat)
Returns a date formatter for the encoded date format.

Parameters:
encodedFormat - the format
Returns:
the formatter

getDateFormatter

Formatter getDateFormatter()
Returns the default date format for the current locale.

Returns:
the date formatter

getDateFormatter

Formatter getDateFormatter(Style style)
Returns the date format with the specified style for the current locale.

Parameters:
style - the style
Returns:
the formatter

getDateTimeFormatter

Formatter getDateTimeFormatter()
Returns the default date/time format for the current locale.

Returns:
the date/time formatter

getDateTimeFormatter

Formatter getDateTimeFormatter(Style dateStyle,
                               Style timeStyle)
Returns the date format with the specified styles for the current locale.

Parameters:
dateStyle - the date style
timeStyle - the time style
Returns:
the formatter

getTimeFormatter

Formatter getTimeFormatter()
Returns the default time format for the current locale.

Returns:
the time formatter

getTimeFormatter

Formatter getTimeFormatter(Style style)
Returns the time format with the specified style for the current locale.

Parameters:
style - the style
Returns:
the formatter

getNumberFormatter

Formatter getNumberFormatter(java.lang.Class numberClass)
Returns a number formatter for the specified class.

Parameters:
numberClass - the number class
Returns:
the number formatter

getPercentFormatter

Formatter getPercentFormatter()
Returns a percent number formatter.

Returns:
the percent formatter

getCurrencyFormatter

Formatter getCurrencyFormatter()
Returns a currency number formatter.

Returns:
the currency formatter


Copyright � 2004-2007. All Rights Reserved.