planetj.formatters
Class CurrencyFormatter

java.lang.Object
  extended byplanetj.formatters.AbstractFormatter
      extended byplanetj.formatters.NumberFormatter
          extended byplanetj.formatters.CurrencyFormatter
All Implemented Interfaces:
IFormatter
Direct Known Subclasses:
FourDecimalCurrencyFormatter, NegativeCurrencyFormatter

public class CurrencyFormatter
extends NumberFormatter


Constructor Summary
CurrencyFormatter()
           
 
Method Summary
 java.lang.String formatValue(java.lang.Object value, Field field)
          This method formats a number (or a String representation of the number that has no commas) to be a string that represents the currency format of the current locale.
 
Methods inherited from class planetj.formatters.NumberFormatter
getNumberFormat
 
Methods inherited from class planetj.formatters.AbstractFormatter
isPrepareFieldValue
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

CurrencyFormatter

public CurrencyFormatter()
Method Detail

formatValue

public java.lang.String formatValue(java.lang.Object value,
                                    Field field)
This method formats a number (or a String representation of the number that has no commas) to be a string that represents the currency format of the current locale. For example, 23434.45 would return $23434.45. If a value is passed in that is not in the right format to be formatted, that value is simply returned

Specified by:
formatValue in interface IFormatter
Overrides:
formatValue in class NumberFormatter
Parameters:
value - java.lang.Object
Returns:
java.lang.Object