org.faceless.graph.formatter
Class FloatingPointFormatter

java.lang.Object
  extended by org.faceless.graph.formatter.Formatter
      extended by org.faceless.graph.formatter.FloatingPointFormatter

public class FloatingPointFormatter
extends Formatter

The FloatingPointFormatter is the default formatter that is used if any values on the axis contain a decimal point.


Field Summary
 
Fields inherited from class org.faceless.graph.formatter.Formatter
MINIMAL, NORMAL, SPARSE
 
Constructor Summary
FloatingPointFormatter()
          Create a new Floating Point Formatter with no minimum number of decimal places, and a maximum of 8 decimal places.
FloatingPointFormatter(int mindp, int maxdp)
          Create a new Floating Point formatter with the specified minimum and maximum number of decimal places.
 
Method Summary
 String format(double in)
          Return a String that is the formatted version of the input parameter.
 
Methods inherited from class org.faceless.graph.formatter.Formatter
isDiscrete, setDensity, setFixedEnds, steps
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

FloatingPointFormatter

public FloatingPointFormatter()
Create a new Floating Point Formatter with no minimum number of decimal places, and a maximum of 8 decimal places. This is the default formatter used if any values on the axis contain a decimal point.


FloatingPointFormatter

public FloatingPointFormatter(int mindp,
                              int maxdp)
Create a new Floating Point formatter with the specified minimum and maximum number of decimal places.

Parameters:
mindp - the minimum number of decimal places to print
maxdp - the maximum number of decumal places to print
Method Detail

format

public String format(double in)
Description copied from class: Formatter
Return a String that is the formatted version of the input parameter.

Specified by:
format in class Formatter


Copyright © 2001-2012 Big Faceless Organization