Package org.opencms.widgets
Class A_CmsCategorizedSelectWidget
java.lang.Object
org.opencms.widgets.A_CmsWidget
org.opencms.widgets.A_CmsCategorizedSelectWidget
- All Implemented Interfaces:
I_CmsADEWidget
,I_CmsWidget
Abstract base class for categorized select widgets.
A categorized select widget consists of two select boxes, one for selecting the actual value and one for filtering the choices available in the first select box. All data for the choices is loaded initially, when the widget is initialized.
-
Nested Class Summary
Nested classes/interfaces inherited from class org.opencms.widgets.A_CmsWidget
A_CmsWidget.CmsDummyWidgetDialog
-
Field Summary
Modifier and TypeFieldDescriptionstatic final I_CmsCategorizedSelectDataFactory
Factory for creating the data for the client-side widget.Fields inherited from class org.opencms.widgets.A_CmsWidget
HELP_POSTFIX, LABEL_PREFIX
-
Constructor Summary
ConstructorDescriptionInstantiates a new a cms categorized select widget.A_CmsCategorizedSelectWidget
(String config) Instantiates a new a cms categorized select widget. -
Method Summary
Modifier and TypeMethodDescriptiongetConfiguration
(CmsObject cms, A_CmsXmlContentValue contentValue, CmsMessages messages, CmsResource resource, Locale contentLocale) Gets the configuration.Gets the css resource links.protected abstract com.google.web.bindery.autobean.shared.AutoBean<I_CmsCategorizedSelectData>
getData
(CmsObject cms, A_CmsXmlContentValue contentValue, CmsMessages messages, CmsResource resource, Locale contentLocale) Gets the select option data for the widget.Gets the default display type.getDialogWidget
(CmsObject cms, I_CmsWidgetDialog widgetDialog, I_CmsWidgetParameter param) Generates the widget HTML for the provided widget parameter.Returns the java script initialization call.Gets the java script resource links.Gets the widget name.boolean
Checks if is internal.Methods inherited from class org.opencms.widgets.A_CmsWidget
equals, getConfiguration, getDialogHtmlEnd, getDialogIncludes, getDialogInitCall, getDialogInitMethod, getHelpBubble, getHelpKey, getHelpText, getJsHelpMouseHandler, getJSIncludeFile, getLabelKey, getWidgetStringValue, hashCode, isCompactViewEnabled, setConfiguration, setEditorValue
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface org.opencms.widgets.I_CmsWidget
getConfiguration, getDialogHtmlEnd, getDialogIncludes, getDialogInitCall, getDialogInitMethod, getHelpBubble, getHelpText, getWidgetStringValue, isCompactViewEnabled, newInstance, setConfiguration, setEditorValue
-
Field Details
-
DATA_FACTORY
Factory for creating the data for the client-side widget.
-
-
Constructor Details
-
A_CmsCategorizedSelectWidget
public A_CmsCategorizedSelectWidget()Instantiates a new a cms categorized select widget. -
A_CmsCategorizedSelectWidget
Instantiates a new a cms categorized select widget.- Parameters:
config
- the config
-
-
Method Details
-
getConfiguration
public String getConfiguration(CmsObject cms, A_CmsXmlContentValue contentValue, CmsMessages messages, CmsResource resource, Locale contentLocale) Gets the configuration.- Specified by:
getConfiguration
in interfaceI_CmsADEWidget
- Parameters:
cms
- the cmscontentValue
- the content valuemessages
- the messagesresource
- the resourcecontentLocale
- the content locale- Returns:
- the configuration
- See Also:
-
getCssResourceLinks
Gets the css resource links.- Specified by:
getCssResourceLinks
in interfaceI_CmsADEWidget
- Parameters:
cms
- the cms- Returns:
- the css resource links
- See Also:
-
getDefaultDisplayType
Gets the default display type.- Specified by:
getDefaultDisplayType
in interfaceI_CmsADEWidget
- Returns:
- the default display type
- See Also:
-
getDialogWidget
public String getDialogWidget(CmsObject cms, I_CmsWidgetDialog widgetDialog, I_CmsWidgetParameter param) Description copied from interface:I_CmsWidget
Generates the widget HTML for the provided widget parameter.- Specified by:
getDialogWidget
in interfaceI_CmsWidget
- Parameters:
cms
- an initialized instance of a CmsObjectwidgetDialog
- the dialog where the widget is used onparam
- the widget parameter to generate the widget for- Returns:
- the widget HTML for the provided widget parameter
- See Also:
-
getInitCall
Description copied from interface:I_CmsADEWidget
Returns the java script initialization call.- Specified by:
getInitCall
in interfaceI_CmsADEWidget
- Returns:
- the java script initialization call
- See Also:
-
getJavaScriptResourceLinks
Gets the java script resource links.- Specified by:
getJavaScriptResourceLinks
in interfaceI_CmsADEWidget
- Parameters:
cms
- the cms- Returns:
- the java script resource links
- See Also:
-
getWidgetName
Gets the widget name.- Specified by:
getWidgetName
in interfaceI_CmsADEWidget
- Returns:
- the widget name
- See Also:
-
isInternal
Checks if is internal.- Specified by:
isInternal
in interfaceI_CmsADEWidget
- Returns:
- true, if is internal
- See Also:
-
getData
protected abstract com.google.web.bindery.autobean.shared.AutoBean<I_CmsCategorizedSelectData> getData(CmsObject cms, A_CmsXmlContentValue contentValue, CmsMessages messages, CmsResource resource, Locale contentLocale) Gets the select option data for the widget.This uses the GWT AutoBean mechanism for serialization. Use the DATA_FACTORY member for creating the relevant AutoBeans.
- Parameters:
cms
- the cmscontentValue
- the content valuemessages
- the messagesresource
- the resourcecontentLocale
- the content locale- Returns:
- the data
-