com.quadrique.jbuildingblocks.core.currency
Class JbbCurrency

java.lang.Object
  extended by com.quadrique.jbuildingblocks.core.currency.JbbCurrency

public class JbbCurrency
extends Object

This class provides convenience routines for currency manipulation: - Currency formating

Version:
1.0.0
Author:
Hervé Rivere

Method Summary
 String formatCurrency(double value)
           
 String formatCurrency(double value, Locale locale)
           
 String formatToEuroInHtml(double value)
           
 String formatToEuroInUnicode(double value)
           
static JbbCurrency newInstance()
           
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Method Detail

newInstance

public static JbbCurrency newInstance()
Returns:
a new instance

formatCurrency

public String formatCurrency(double value)
                      throws Exception
Parameters:
value -
Returns:
the given value as a currency string in the default format for the default locale
Throws:
Exception

formatCurrency

public String formatCurrency(double value,
                             Locale locale)
                      throws Exception
Parameters:
value -
locale -
Returns:
the given value as a currency string in the default format for the given locale
Throws:
Exception

formatToEuroInUnicode

public String formatToEuroInUnicode(double value)
                             throws Exception
Parameters:
value -
Returns:
the given value (encoded in Unicode)
Throws:
Exception

formatToEuroInHtml

public String formatToEuroInHtml(double value)
                          throws Exception
Parameters:
value -
Returns:
the given value in euro (encoded in HTML)
Throws:
Exception


Copyright © 2001-2008 Quadrique Corporation. All Rights Reserved.