Class DefaultEnumEditor
- java.lang.Object
-
- com.hybris.cockpitng.editors.impl.AbstractCockpitEditorRenderer<java.lang.Object>
-
- com.hybris.cockpitng.editor.defaultenum.DefaultEnumEditor
-
- All Implemented Interfaces:
CockpitEditorRenderer<java.lang.Object>
public class DefaultEnumEditor extends AbstractCockpitEditorRenderer<java.lang.Object>
Editor dealing with enumeration values.
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description protected classDefaultEnumEditor.FilteredListModelList<E>
-
Field Summary
Fields Modifier and Type Field Description protected CockpitLocaleServicecockpitLocaleServiceprotected CockpitPropertiescockpitPropertiesstatic intENTER_CODE_KEYprotected EnumValueResolverenumValueResolverprotected LabelServicelabelServiceprotected static java.util.regex.PatternPATTERN_ENUM-
Fields inherited from class com.hybris.cockpitng.editors.impl.AbstractCockpitEditorRenderer
HEADER_LABEL_TOOLTIP, ON_ADD_EVENT, ON_DELETE_EVENT, YW_EDITOR_AREA_LABEL_CONTAINER
-
Fields inherited from interface com.hybris.cockpitng.editors.CockpitEditorRenderer
INITIAL_EDIT_STRING
-
-
Constructor Summary
Constructors Constructor Description DefaultEnumEditor()
-
Method Summary
All Methods Instance Methods Concrete Methods Deprecated Methods Modifier and Type Method Description protected java.util.List<java.lang.Object>getAllValues(EditorContext<java.lang.Object> context, java.lang.Object initialValue)protected java.util.List<java.lang.Object>getAllValues(java.lang.String valueType, java.lang.Object initialValue)Deprecated, for removal: This API element is subject to removal in a future version.since 2005, usegetAllValues(EditorContext, Object)insteadprotected EnumValueResolvergetEnumValueResolver(EditorContext<java.lang.Object> context)protected booleanisOptional(EditorContext<java.lang.Object> context)protected java.lang.StringmapEnumToString(java.lang.Object value, EditorContext<java.lang.Object> context)voidrender(org.zkoss.zk.ui.Component parent, EditorContext<java.lang.Object> context, EditorListener<java.lang.Object> listener)Creates a new editor component and attaches it to the specifiedComponentcomponent.-
Methods inherited from class com.hybris.cockpitng.editors.impl.AbstractCockpitEditorRenderer
extractEmbeddedEditor, extractEmbeddedType, findAncestorEditor, findEmbeddedEditors, getInitialEditString, getL10nDecorator
-
-
-
-
Field Detail
-
ENTER_CODE_KEY
public static final int ENTER_CODE_KEY
- See Also:
- Constant Field Values
-
PATTERN_ENUM
protected static final java.util.regex.Pattern PATTERN_ENUM
-
enumValueResolver
protected EnumValueResolver enumValueResolver
-
labelService
protected LabelService labelService
-
cockpitLocaleService
protected CockpitLocaleService cockpitLocaleService
-
cockpitProperties
protected CockpitProperties cockpitProperties
-
-
Method Detail
-
render
public void render(org.zkoss.zk.ui.Component parent, EditorContext<java.lang.Object> context, EditorListener<java.lang.Object> listener)Description copied from interface:CockpitEditorRendererCreates a new editor component and attaches it to the specifiedComponentcomponent.- Parameters:
parent- parent component the editor should be attached tocontext- the context for the editor creationlistener- the listener to notify the rest of the world about value changes and other events
-
mapEnumToString
protected java.lang.String mapEnumToString(java.lang.Object value, EditorContext<java.lang.Object> context)
-
getAllValues
@Deprecated(since="2005", forRemoval=true) protected java.util.List<java.lang.Object> getAllValues(java.lang.String valueType, java.lang.Object initialValue)Deprecated, for removal: This API element is subject to removal in a future version.since 2005, usegetAllValues(EditorContext, Object)instead
-
getAllValues
protected java.util.List<java.lang.Object> getAllValues(EditorContext<java.lang.Object> context, java.lang.Object initialValue)
-
getEnumValueResolver
protected EnumValueResolver getEnumValueResolver(EditorContext<java.lang.Object> context)
-
isOptional
protected boolean isOptional(EditorContext<java.lang.Object> context)
-
-