public class ColumnUtils extends Object
| Constructor and Description |
|---|
ColumnUtils() |
| Modifier and Type | Method and Description |
|---|---|
Object |
getColumnAttribute(ColumnExpr columnExpr,
String name)
Returns the column attribute
|
int |
getColumnMaxLength(ColumnExpr columnExpr) |
NumberFormat |
getColumnNumberFormat(ColumnExpr columnExpr,
Locale locale) |
double |
getColumnSize(ColumnExpr columnExpr)
Return the size of the column of 0.0d if unknown
|
static ColumnUtils |
getInstance() |
static int |
getMaxLength(ColumnExpr columnExpr)
Return the maximum character length of a columnExpr
|
static Number |
getMaxValue(ColumnExpr columnExpr)
Returns the maximum allowed value
|
static int |
getMinLength(ColumnExpr columnExpr)
Returns the minimum length, usually 0
|
static Number |
getMinValue(ColumnExpr columnExpr)
Returns the maximum allowed value or 0 if not set
|
static NumberFormat |
getNumberFormat(ColumnExpr columnExpr,
Locale locale)
Returns the number format for a particular columnExpr
|
void |
setColumnNumberFormat(ColumnExpr columnExpr,
String numberType,
boolean groupSeparator) |
static void |
setInstance(ColumnUtils columnUtils) |
static <T extends ColumnExpr> |
setMinMaxValue(T columnExpr,
Number minValue,
Number maxValue)
Set the minimum and maximum values of a columnExpr
|
static <T extends ColumnExpr> |
setNumberFormat(T columnExpr,
String numberType,
boolean groupSeparator)
Sets the number format options for a columnExpr
|
public static ColumnUtils getInstance()
public static void setInstance(ColumnUtils columnUtils)
public static int getMinLength(ColumnExpr columnExpr)
columnExpr - the columnExprpublic static int getMaxLength(ColumnExpr columnExpr)
columnExpr - the columnExprpublic static Number getMinValue(ColumnExpr columnExpr)
columnExpr - the columnExprpublic static Number getMaxValue(ColumnExpr columnExpr)
columnExpr - the columnExprpublic static <T extends ColumnExpr> T setMinMaxValue(T columnExpr, Number minValue, Number maxValue)
columnExpr - the columnExprminValue - the min valuemaxValue - the max valuepublic static NumberFormat getNumberFormat(ColumnExpr columnExpr, Locale locale)
columnExpr - the columnExprlocale - the locale for which to get the formatpublic static <T extends ColumnExpr> T setNumberFormat(T columnExpr, String numberType, boolean groupSeparator)
columnExpr - the column expressionnumberType - the number typegroupSeparator - should be usedpublic Object getColumnAttribute(ColumnExpr columnExpr, String name)
columnExpr - the column expressionname - the attribute namepublic double getColumnSize(ColumnExpr columnExpr)
columnExpr - the column expressionpublic int getColumnMaxLength(ColumnExpr columnExpr)
public NumberFormat getColumnNumberFormat(ColumnExpr columnExpr, Locale locale)
public void setColumnNumberFormat(ColumnExpr columnExpr, String numberType, boolean groupSeparator)
Copyright © 2008–2023 Apache Software Foundation. All rights reserved.