org.eclipse.birt.chart.computation
Class ValueFormatter

java.lang.Object
  extended by org.eclipse.birt.chart.computation.ValueFormatter

public final class ValueFormatter
extends java.lang.Object

This class handles the formatting work of any data value.


Constructor Summary
ValueFormatter()
           
 
Method Summary
static java.lang.String format(java.lang.Object oValue, FormatSpecifier fs, com.ibm.icu.util.ULocale lcl, java.lang.Object oCachedJavaFormatter)
          Returns the formatted string representation of given object.
static java.lang.String getNumericPattern(double dValue)
          Returns an auto computed decimal format pattern for category data or axis label.
static java.lang.String getNumericPattern(java.lang.Number num)
           
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

ValueFormatter

public ValueFormatter()
Method Detail

format

public static final java.lang.String format(java.lang.Object oValue,
                                            FormatSpecifier fs,
                                            com.ibm.icu.util.ULocale lcl,
                                            java.lang.Object oCachedJavaFormatter)
                                     throws ChartException
Returns the formatted string representation of given object.

Parameters:
oValue -
fs -
lcl -
Returns:
formatted string
Throws:
ChartException

getNumericPattern

public static java.lang.String getNumericPattern(java.lang.Number num)
Parameters:
num -
Returns:
Since:
2.5.3

getNumericPattern

public static java.lang.String getNumericPattern(double dValue)
Returns an auto computed decimal format pattern for category data or axis label. If it's an integer, no decimal point and no separator. This is also used for representing logarithmic values.

Returns:
numeric pattern


Copyright © 2005-2008 Actuate Corp. All rights reserved.