Package org.faceless.graph.formatter
Class FloatingPointFormatter
- java.lang.Object
-
- org.faceless.graph.formatter.Formatter
-
- 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.
-
-
Constructor Summary
Constructors Constructor Description 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
All Methods Instance Methods Concrete Methods Modifier and Type Method Description java.lang.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
fixMinMax, isDiscrete, setDensity, setFixedEnds, steps
-
-
-
-
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 printmaxdp
- the maximum number of decumal places to print
-
-