org.eclipse.nebula.widgets.nattable.edit
Class DialogEditHandler
java.lang.Object
org.eclipse.nebula.widgets.nattable.edit.DialogEditHandler
- All Implemented Interfaces:
- ICellEditHandler
public class DialogEditHandler
- extends Object
- implements ICellEditHandler
ICellEditHandler
implementation for editing within a dialog.
It will simply store the committed value so it can be propagated to
the data model by the caller of the dialog.
Note: On using this handler you are forced to call the UpdateDataCommand
or any other action to update the data model yourself!
- Author:
- Dirk Fauth
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
DialogEditHandler
public DialogEditHandler()
commit
public boolean commit(Object canonicalValue,
SelectionLayer.MoveDirectionEnum direction)
- This implementation will simply store the committed value in this handler.
This way the caller of the dialog that uses this handler is able to update
the data model and handle the selection itself.
This implementation always returns true
leaving the editor in
control if it should be closed after commit. The behaviour is mainly different
in terms of where the editor is opened, inline or in a subdialog. But as it
is also related to the editor itself, e.g. a text editor will remain visible
while a NatCombo will disappear after commit, the editor itself needs to
take care of the closing.
- Specified by:
commit
in interface ICellEditHandler
- Parameters:
canonicalValue
- The value to commit.direction
- The direction to move the selection after commit.
- Returns:
true
if the data update succeeded, false
if something went wrong
getCommittedValue
public Object getCommittedValue()
- Returns:
- The value that should be used to update the data model.
Copyright © 2014. All rights reserved.