public class SelectField extends AbstractField<Object>
Modifier and Type | Field and Description |
---|---|
static String |
AUTOCOMPLETE_SUFFIX |
protected String |
autocompleteId |
protected String |
autocompleteInputName |
protected String |
autocompleteInputValue |
protected String |
comboLabel |
static String |
copyright |
protected String |
createNewValueHref |
protected String |
createNewValueText |
protected DisplayMode |
displayMode |
protected SelectField |
nextSelectField |
protected SelectField |
previousSelectField |
protected SelectionModel |
selectionModel |
protected int |
selectionModelIndex |
accessor, bulkCheckboxName, bulkChecked, colSpan, COPYRIGHT, EDITABLE_FIELD_CSS_CLASS, elementsConfiguration, enabled, errors, fieldCssClass, forceNewRow, FORM_LABEL_CSS_CLASS, help, href, id, INPUT_CONTAINER_CSS_CLASS, inputName, insertable, label, logger, mode, required, STATIC_VALUE_CSS_CLASS, title, updatable
Constructor and Description |
---|
SelectField(PropertyAccessor accessor,
Mode mode,
String prefix) |
SelectField(PropertyAccessor accessor,
SelectionProvider selectionProvider,
Mode mode,
String prefix) |
closeVisibleField, errorsToXhtml, getColSpan, getDisplayValue, getErrors, getFieldCssClass, getHelp, getHref, getId, getInputName, getLabel, getMode, getPropertyAccessor, getText, getTitle, hasRequiredFields, helpToXhtml, isBlank, isEnabled, isForceNewRow, isInsertable, isReadOnly, isRequired, isUpdatable, isValid, labelToXhtml, maybeConvertValue, openVisibleField, readFrom, setColSpan, setEnabled, setErrors, setFieldCssClass, setForceNewRow, setHelp, setHref, setId, setInputName, setInsertable, setLabel, setRequired, setTitle, setUpdatable, toXhtml, writeTo, writeToObject, writeToObject
public static final String copyright
public static final String AUTOCOMPLETE_SUFFIX
protected SelectionModel selectionModel
protected int selectionModelIndex
protected SelectField previousSelectField
protected SelectField nextSelectField
protected String comboLabel
protected DisplayMode displayMode
protected String autocompleteId
protected String autocompleteInputName
protected String autocompleteInputValue
protected String createNewValueHref
protected String createNewValueText
public SelectField(PropertyAccessor accessor, Mode mode, String prefix)
public SelectField(PropertyAccessor accessor, SelectionProvider selectionProvider, Mode mode, String prefix)
public SelectionProvider createEnumSelectionProvider(PropertyAccessor accessor)
public SelectionProvider createValuesSelectionProvider(PropertyAccessor accessor, Object[] values, String[] labels)
public void readFromRequest(HttpServletRequest req)
readFromRequest
in interface Element
readFromRequest
in class AbstractField<Object>
public boolean validate()
public void readFromObject(Object obj)
readFromObject
in interface Element
readFromObject
in class AbstractField<Object>
public void writeToObject(Object obj)
public void valueToXhtml(XhtmlBuffer xb)
public void valueToXhtmlEdit(XhtmlBuffer xb)
protected void addCreateNewLink(XhtmlBuffer xb)
public String composeCreateNewJs()
public void valueToXhtmlEditDropDown(XhtmlBuffer xb)
public String composeDropDownJs()
public String composeAutocompleteJs()
public void appendIds(StringBuilder sb)
public void valueToXhtmlEditRadio(XhtmlBuffer xb)
protected void writeRadioWithLabel(XhtmlBuffer xb, String radioId, String label, String stringValue, boolean checked)
public void valueToXhtmlEditAutocomplete(XhtmlBuffer xb)
public void valueToXhtmlPreview(XhtmlBuffer xb)
public void valueToXhtmlHidden(XhtmlBuffer xb)
public void valueToXhtmlView(XhtmlBuffer xb)
public String getStringValue()
public void setStringValue(String stringValue)
public String jsonSelectFieldOptions(boolean includeSelectPrompt)
public Object getValue()
public void setValue(Object value)
public Map<Object,SelectionModel.Option> getOptions()
public String getLabelSearch()
public String getComboLabel()
public void setComboLabel(String comboLabel)
public String getAutocompleteId()
public SelectField getNextSelectField()
public void setNextSelectField(SelectField nextSelectField)
public SelectField getPreviousSelectField()
public void setPreviousSelectField(SelectField previousSelectField)
public void setAutocompleteId(String autocompleteId)
public String getAutocompleteInputName()
public void setAutocompleteInputName(String autocompleteInputName)
public void setLabelSearch(String labelSearch)
public SelectionModel getSelectionModel()
public void setSelectionModel(SelectionModel selectionModel)
public int getSelectionModelIndex()
public void setSelectionModelIndex(int selectionModelIndex)
public DisplayMode getDisplayMode()
public void setDisplayMode(DisplayMode displayMode)
public String getCreateNewValueHref()
public void setCreateNewValueHref(String createNewValueHref)
public String getCreateNewValueText()
public void setCreateNewValueText(String createNewValueText)