public class DataTypeField extends AbstractField
DataTypeField(Cloud, DataType) to have a 'virtual field with a Virtual NodeManager with only one field
(itself). The constructor DataTypeField(Field, DataType), produces a new field object,
that is very similar to the one wrapped, only with a different DataType.
This also a way to associate a Cloud object with a DataType (it is actually possible to see that
as the essence of being a Field).| Modifier and Type | Field and Description |
|---|---|
protected Field |
field |
protected NodeManager |
nodeManager |
dataType, listItemType, readOnly, state, typedescription, guiName, keySTATE_PERSISTENT, STATE_SYSTEM, STATE_SYSTEM_VIRTUAL, STATE_UNKNOWN, STATE_VIRTUAL, TYPE_BINARY, TYPE_BOOLEAN, TYPE_BYTE, TYPE_DATETIME, TYPE_DECIMAL, TYPE_DOUBLE, TYPE_FLOAT, TYPE_INTEGER, TYPE_LIST, TYPE_LONG, TYPE_NODE, TYPE_STRING, TYPE_UNKNOWN, TYPE_XML| Constructor and Description |
|---|
DataTypeField(Cloud cloud,
DataType<? extends Object> dataType) |
DataTypeField(Field field,
DataType<? extends Object> dataType)
This constructor only wraps the given field to have another datatype.
|
DataTypeField(NodeManager nm,
Field f) |
DataTypeField(String name,
NodeManager nm,
DataType<? extends Object> dataType) |
| Modifier and Type | Method and Description |
|---|---|
int |
getEditPosition()
Retrieve the position of the field when editing.
|
String |
getGUIType()
Returns the GUI name for the data type this field contains.
|
int |
getListPosition()
Retrieve the position of the field when listing.
|
int |
getMaxLength()
Returns the maximum length of data this field can contain.
|
NodeManager |
getNodeManager()
Returns the node manager this field belongs to.
|
int |
getSearchPosition()
Retrieve the position of the field when searching.
|
int |
getStoragePosition()
Retrieve the position of the field in the database table.
|
boolean |
isReadOnly()
Returns whether a field is a read only.
|
Collection<String> |
validate(Object value)
Checks whether a given value is valid for this field.
|
clone, clone, compareTo, equals, getDataType, getListItemType, getState, getType, hashCode, hasIndex, isRequired, isTemporary, isUnique, isVirtual, setDataType, setState, toStringclone, getDefaultLocale, getDescription, getDescription, getGUIName, getGUIName, getLocalizedDescription, getLocalizedGUIName, getName, setDescription, setDescription, setGUIName, setGUIName, setLocalizedDescription, setLocalizedGUINamefinalize, getClass, notify, notifyAll, wait, wait, waitgetDescription, getDescription, getGUIName, getGUIName, getLocalizedDescription, getLocalizedGUIName, getName, setDescription, setDescription, setGUIName, setGUINameprotected final NodeManager nodeManager
protected final Field field
public DataTypeField(NodeManager nm, Field f)
public DataTypeField(String name, NodeManager nm, DataType<? extends Object> dataType)
public NodeManager getNodeManager()
FieldgetNodeManager in interface FieldgetNodeManager in class AbstractFieldpublic int getSearchPosition()
FieldgetSearchPosition in interface FieldgetSearchPosition in class AbstractFieldpublic int getListPosition()
FieldgetListPosition in interface FieldgetListPosition in class AbstractFieldpublic int getEditPosition()
FieldgetEditPosition in interface FieldgetEditPosition in class AbstractFieldpublic int getStoragePosition()
FieldgetStoragePosition in interface FieldgetStoragePosition in class AbstractFieldpublic int getMaxLength()
FieldgetMaxLength in interface FieldgetMaxLength in class AbstractFieldpublic boolean isReadOnly()
AbstractFieldisReadOnly in interface FieldisReadOnly in class AbstractFieldtrue when read onlyField.isVirtual()public String getGUIType()
FieldgetGUIType in interface FieldgetGUIType in class AbstractFieldField.getDataType()public Collection<String> validate(Object value)
Fieldvalue - value to validateMMBase 1.9-SNAPSHOT - ${javadoctimestamp}