Class DefaultPropertyEditorBean
java.lang.Object
de.hybris.platform.cockpit.model.meta.impl.DefaultPropertyEditorBean
- All Implemented Interfaces:
PropertyEditorBean
- Direct Known Subclasses:
DefaultZKPropertyEditorBean
Base class for property editor backing beans. Provides original and current value, modification check and connection
to parent descriptor.
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionfinal PropertyEditorDescriptorThe descriptor which this beans belong to.getValue()Returns the current value.voidinitialize(Object value) Initializes the editor bean by specifying the start value.booleanTells whether the editor allows changes.booleanTells whether this editor shows invalid state.booleanTells whether this bean contains a modified value compared to the start value.voidreset()Resets the editor to the initial value.final voidsetEditable(boolean editable) Switches editing on and off.voidsetInvalid(boolean invalid) Switches invalid state of this editor bean.voidChanges the current value.voidprotected voidupdateEditable(boolean newEditable) Called each time the editable flag has been changed.protected voidupdateInvalid(boolean newInvalid) Called each time the invalid flag has been changed.
-
Constructor Details
-
DefaultPropertyEditorBean
-
-
Method Details
-
updateEditable
protected void updateEditable(boolean newEditable) Called each time the editable flag has been changed. The component should be modified to block or allow user input.- Parameters:
newEditable- the new editable flag value
-
setEditable
public final void setEditable(boolean editable) Description copied from interface:PropertyEditorBeanSwitches editing on and off. This will not change the modification state!- Specified by:
setEditablein interfacePropertyEditorBean- Parameters:
editable- true if the component should be allow changes
-
isEditable
public boolean isEditable()Description copied from interface:PropertyEditorBeanTells whether the editor allows changes.- Specified by:
isEditablein interfacePropertyEditorBean
-
getDescriptor
Description copied from interface:PropertyEditorBeanThe descriptor which this beans belong to.- Specified by:
getDescriptorin interfacePropertyEditorBean
-
getValue
Description copied from interface:PropertyEditorBeanReturns the current value.- Specified by:
getValuein interfacePropertyEditorBean
-
getValues
-
setValues
-
initialize
Description copied from interface:PropertyEditorBeanInitializes the editor bean by specifying the start value. This will reset all previous changes. Therefore the editor bean wont be modified any longer!- Specified by:
initializein interfacePropertyEditorBean- Parameters:
value- the start value
-
reset
public void reset()Description copied from interface:PropertyEditorBeanResets the editor to the initial value. Also clears invalid flag. Editable flag remains untouched!- Specified by:
resetin interfacePropertyEditorBean
-
isModified
public boolean isModified()Description copied from interface:PropertyEditorBeanTells whether this bean contains a modified value compared to the start value.- Specified by:
isModifiedin interfacePropertyEditorBean- See Also:
-
setValue
Description copied from interface:PropertyEditorBeanChanges the current value. If the value is different from the start value the bean is marked modified.- Specified by:
setValuein interfacePropertyEditorBean
-
isInvalid
public boolean isInvalid()Description copied from interface:PropertyEditorBeanTells whether this editor shows invalid state.- Specified by:
isInvalidin interfacePropertyEditorBean
-
updateInvalid
protected void updateInvalid(boolean newInvalid) Called each time the invalid flag has been changed. The component may signal this fact accordingly.- Parameters:
newInvalid- the new invalid flag value
-
setInvalid
public void setInvalid(boolean invalid) Description copied from interface:PropertyEditorBeanSwitches invalid state of this editor bean.- Specified by:
setInvalidin interfacePropertyEditorBean- Parameters:
invalid- true if the editor should show invalid state
-