com.vaadin.ui
Class Grid.EditorFieldFactory
java.lang.Object
com.vaadin.data.fieldgroup.DefaultFieldGroupFieldFactory
com.vaadin.ui.Grid.EditorFieldFactory
- All Implemented Interfaces:
- FieldGroupFieldFactory, java.io.Serializable
- Enclosing class:
- Grid
public static class Grid.EditorFieldFactory
- extends DefaultFieldGroupFieldFactory
Field factory used by default in the editor.
Aims to fields of suitable type and with suitable size for use in the
editor row.
- See Also:
- Serialized Form
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Grid.EditorFieldFactory
protected Grid.EditorFieldFactory()
get
public static Grid.EditorFieldFactory get()
- Returns the singleton instance
- Returns:
- the singleton instance
createField
public <T extends Field> T createField(java.lang.Class<?> type,
java.lang.Class<T> fieldType)
- Description copied from interface:
FieldGroupFieldFactory
- Creates a field based on the data type that we want to edit
- Specified by:
createField
in interface FieldGroupFieldFactory
- Overrides:
createField
in class DefaultFieldGroupFieldFactory
- Parameters:
type
- The type that we want to edit using the fieldfieldType
- The type of field we want to create. If set to Field
then any type of field is accepted
- Returns:
- A field that can be assigned to the given fieldType and that is
capable of editing the given type of data
createCompatibleSelect
protected AbstractSelect createCompatibleSelect(java.lang.Class<? extends AbstractSelect> fieldType)
- Overrides:
createCompatibleSelect
in class DefaultFieldGroupFieldFactory
populateWithEnumData
protected void populateWithEnumData(AbstractSelect select,
java.lang.Class<? extends java.lang.Enum> enumClass)
- Description copied from class:
DefaultFieldGroupFieldFactory
- Populates the given select with all the enums in the given
Enum
class. Uses Enum
.toString() for caption.
- Overrides:
populateWithEnumData
in class DefaultFieldGroupFieldFactory
- Parameters:
select
- The select to populateenumClass
- The Enum class to use
Copyright © 2000-2014 Vaadin Ltd. All Rights Reserved.