Package org.opencms.gwt.client.ui.input
Interface I_CmsFormWidget
- All Known Implementing Classes:
A_CmsSelectBox
,CmsCategoryField
,CmsCheckBox
,CmsColorPicker
,CmsComboBox
,CmsDateBox
,CmsExtendedMultiCheckBox
,CmsFilterSelectBox
,CmsFocusAwareTextBox
,CmsGalleryField
,CmsImageGalleryField
,CmsLinkSelector
,CmsMultiCheckBox
,CmsMultiSelectBox
,CmsPrincipalSelection
,CmsPropertyComboBox
,CmsPropertySelectBox
,CmsRadioButtonGroupWidget
,CmsSelectBox
,CmsSelectComboBox
,CmsTextArea
,CmsTextBox
,CmsTinyMCEWidget
,CmsVfsLinkWidget
,CmsVfsSelection
public interface I_CmsFormWidget
Basic interface for all widgets that can be used for form fields.
- Since:
- 8.0.0
-
Nested Class Summary
Nested Classes -
Method Summary
Modifier and TypeMethodDescriptionReturns the "apparent value", i.e.Returns the type of data this widget produces.Gets the selected/entered value from the widget.Gets the current value of the widget as a string.boolean
Returnstrue
if this widget is enabled.void
reset()
Resets the widget to its default state.void
setAutoHideParent
(I_CmsAutoHider autoHideParent) Call this when auto hiding parents are shown.void
setEnabled
(boolean enabled) Enables or disables the widget.void
setErrorMessage
(String errorMessage) Sets the error message for this widget.void
setFormValueAsString
(String value) Sets the current value of the widget as a string.
-
Method Details
-
getApparentValue
Returns the "apparent value", i.e. either the real value if available, or else the ghost value if available, or null otherwise.- Returns:
- the apparent value
-
getFieldType
Returns the type of data this widget produces.- Returns:
- the data type
-
getFormValue
Gets the selected/entered value from the widget.- Returns:
- the value
-
getFormValueAsString
Gets the current value of the widget as a string.- Returns:
- the current value of the widget
-
isEnabled
boolean isEnabled()Returnstrue
if this widget is enabled.- Returns:
true
if this widget is enabled
-
reset
void reset()Resets the widget to its default state. -
setAutoHideParent
Call this when auto hiding parents are shown.- Parameters:
autoHideParent
- the auto hide parent
-
setEnabled
Enables or disables the widget.- Parameters:
enabled
- if true, the widget will be enabled, else disabled
-
setErrorMessage
Sets the error message for this widget.If the error message is null, no error message will be displayed.
- Parameters:
errorMessage
- an error message or null
-
setFormValueAsString
Sets the current value of the widget as a string.- Parameters:
value
- the new value of the widget
-