public class UIFormat
extends java.lang.Object
Constructor and Description |
---|
UIFormat() |
Modifier and Type | Method and Description |
---|---|
static java.lang.String |
currencyToStr(AppInterface appI,
double amount,
boolean bSymbol,
boolean bThousSep,
boolean bPadSpaces)
Formats a currency value to the format of the functional currency.
|
static java.lang.String |
dateTimeToStr(AppInterface appI,
java.util.Calendar datetime,
boolean bDate,
boolean bTime,
boolean bFourDigitYear)
Formats a date time value to the format of the functional currency.
|
static java.lang.String |
numberToStr(AppInterface appI,
double amount,
int nScale,
boolean bThousSep,
boolean bPadDec)
Formats a numeric value to the format of the functional currency.
|
static java.lang.String |
percentToStr(AppInterface appI,
double amount,
int nScale,
boolean bThousSep,
boolean bPadDec)
Formats a percentage amount to the format of the functional currency.
|
public static java.lang.String currencyToStr(AppInterface appI, double amount, boolean bSymbol, boolean bThousSep, boolean bPadSpaces)
appI
- AppInterface appI application interface.amount
- Double amount value to convert to a string.bSymbol
- boolean bSymbol set to "true" to include currency symbol.bThousSep
- boolean bThousSep set to "true" to include thousands separator symbol.bPadSpaces
- boolean bPadSpaces set to "true" to pad string value with spaces in order to align amounts.public static java.lang.String numberToStr(AppInterface appI, double amount, int nScale, boolean bThousSep, boolean bPadDec)
appI
- AppInterface appI application interface.amount
- Double amount value to convert to a string.nScale
- int nScale decimal precision to use.bThousSep
- boolean bThousSep set to "true" to include thousands separator symbol.bPadDec
- boolean bPadDec set to "true" to pad decimal segment with zeros.public static java.lang.String percentToStr(AppInterface appI, double amount, int nScale, boolean bThousSep, boolean bPadDec)
appI
- AppInterface appI application interface.amount
- Double amount decimal value to convert to a percentage.nScale
- int nScale decimal precision to use for the formatted string.bThousSep
- boolean bThousSep set to "true" to include thousands separator symbol.bPadDec
- boolean bPadDec set to "true" to pad decimal segment with zeros.public static java.lang.String dateTimeToStr(AppInterface appI, java.util.Calendar datetime, boolean bDate, boolean bTime, boolean bFourDigitYear)
appI
- AppInterface appI application interface.datetime
- Calendar datetime datetime value to convert to a string.bDate
- boolean bDate set to "true" to include date segment.bTime
- boolean bTime set to "true" to include time segment.bFourDigitYear
- boolean bFourDigitYear set to "true" to use four digit year.