public class BeanProperty extends Object implements Column
| Modifier and Type | Field and Description |
|---|---|
protected BeanClass |
beanClass |
COLATTR_CURRENCY_CODE, COLATTR_DATETIMEPATTERN, COLATTR_ENUMTYPE, COLATTR_FRACTION_DIGITS, COLATTR_INTEGER_DIGITS, COLATTR_MAXVALUE, COLATTR_MINLENGTH, COLATTR_MINVALUE, COLATTR_NULLTEXT, COLATTR_NUMBER_GROUPSEP, COLATTR_NUMBER_TYPE, COLATTR_REGEXP, COLATTR_TITLE, COLATTR_TOOLTIP, COLATTR_TYPE| Constructor and Description |
|---|
BeanProperty(String name,
DataType dataType,
double size,
boolean required)
Constructs a bean property definition
|
BeanProperty(String name,
DataType dataType,
double size,
boolean required,
String controlType)
Constructs a bean property definition
|
BeanProperty(String name,
DataType dataType,
double size,
boolean required,
String controlType,
boolean readOnly)
Constructs a bean property definition
|
| Modifier and Type | Method and Description |
|---|---|
Object |
getAttribute(String name)
Returns the value of a column attribute.
|
Set<Attributes.Attribute> |
getAttributes()
Returns all metadata attributes.
|
BeanClass |
getBeanClass()
returns the bean class of this property.
|
String |
getBeanPropertyName()
Gets the Java bean property name.
|
String |
getControlType()
Returns the columns control type.
|
DataType |
getDataType()
Returns the data type of the bean property.
|
EntityType |
getEntityType()
Returns the EntityType that this Column belongs to
|
Class<Enum<?>> |
getEnumType()
Returns the enum type for this column
|
String |
getName()
Returns the name of the property.
|
Options |
getOptions()
Returns the list of options for this column
containing all allowed field values.
|
double |
getSize()
Returns the maximum size a value for this column is allowed to have.
|
Column |
getSourceColumn()
Deprecated.
|
String |
getTitle()
Returns the title attribute.
|
Column |
getUpdateColumn()
Returns the underlying source column (if any).
|
boolean |
isAutoGenerated()
Returns whether or not the value for this column is auto-generated
|
boolean |
isReadOnly()
Returns true if the values for this column are generally
read only (like i.e. for sequence generated values).
|
boolean |
isRequired()
Returns whether or not the value for this column must be
supplied (i.e. it is mandatory) or not.
|
void |
setAttribute(String name,
Object value) |
void |
setControlType(String controlType) |
void |
setOptions(Options options) |
void |
setTitle(String title) |
Object |
validateValue(Object value)
Checks if the given value is a valid value for this column
If not, an exception is thrown
|
protected BeanClass beanClass
public BeanProperty(String name, DataType dataType, double size, boolean required, String controlType, boolean readOnly)
name - the name of the propertydataType - the type of the propertysize - the sizerequired - flag true if requiredcontrolType - string indication which type of control to usereadOnly - flag true if read-onlypublic BeanProperty(String name, DataType dataType, double size, boolean required, String controlType)
name - the name of the propertydataType - the type of the propertysize - the sizerequired - flag true if requiredcontrolType - string indication which type of control to usepublic EntityType getEntityType()
ColumngetEntityType in interface Columnpublic String getName()
getName in interface ColumnExprpublic DataType getDataType()
getDataType in interface ColumnExprDataTypepublic Object getAttribute(String name)
getAttribute in interface ColumnExprname - the attribute namepublic Set<Attributes.Attribute> getAttributes()
getAttributes in interface Columnpublic String getTitle()
getTitle in interface ColumnExprpublic Options getOptions()
getOptions in interface ColumnExprpublic Class<Enum<?>> getEnumType()
getEnumType in interface ColumnExprpublic String getControlType()
getControlType in interface ColumnExprpublic String getBeanPropertyName()
getBeanPropertyName in interface ColumnExprpublic Column getUpdateColumn()
ColumnExprgetUpdateColumn in interface ColumnExpr@Deprecated public final Column getSourceColumn()
getSourceColumn in interface ColumnExprpublic double getSize()
ColumnFor the data type DECIMAL the size defines the scale and precision of the value.
public boolean isReadOnly()
ColumnisReadOnly in interface Columnpublic boolean isAutoGenerated()
ColumnisAutoGenerated in interface Columnpublic boolean isRequired()
ColumnisRequired in interface Columnpublic Object validateValue(Object value)
ColumnvalidateValue in interface Columnvalue - the value to validatepublic BeanClass getBeanClass()
null if BeanProperty is used 'stand alone'public void setControlType(String controlType)
public void setOptions(Options options)
public void setTitle(String title)
Copyright © 2008–2023 Apache Software Foundation. All rights reserved.