|
Dashboard Builder Commons 6.0.0.Beta4 | |||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.jboss.dashboard.commons.text.DecimalFormatUtil
public class DecimalFormatUtil
Utilities for formating and parsing decimal numbers.
| Method Summary | |
|---|---|
static String |
doubleToStr(double origin,
int decimals)
Formats a double to produce a string with a number of fraction digits. |
static String |
doubleToStr(Number origin,
int decimals)
Formats a Number to produce a string with a number of fraction digits. |
static boolean |
isValidDouble(String value,
int decimals)
Tell whether a double string is in valid format, according with a number of fraction digits. |
static boolean |
isValidFloat(String value,
int decimals)
Tell whether a float string is in valid format, according with a number of fraction digits. |
static Double |
strToDouble(String text,
int decimals)
Parses a string to produce a Double with a number of fraction digits. |
static Float |
strToFloat(String text,
int decimals)
Parses a string to produce a Float with a number of fraction digits. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Method Detail |
|---|
public static String doubleToStr(double origin,
int decimals)
origin - double to formatdecimals - number of fraction digits
public static String doubleToStr(Number origin,
int decimals)
origin - Number to formatdecimals - number of fraction digits
public static Double strToDouble(String text,
int decimals)
text - string to parsedecimals - number of fraction digits
public static Float strToFloat(String text,
int decimals)
text - string to parsedecimals - number of fraction digits
public static boolean isValidDouble(String value,
int decimals)
value - the double string to be testeddecimals - number of decimals
public static boolean isValidFloat(String value,
int decimals)
value - the float string to be testeddecimals - number of decimals
|
Dashboard Builder Commons 6.0.0.Beta4 | |||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||