Class RowDeleteDataChange
java.lang.Object
org.eclipse.nebula.widgets.nattable.datachange.RowDeleteDataChange
- All Implemented Interfaces:
DataChange
DataChange
implementation to track row delete operations. Is used in
persistent mode and can only discard a row delete operation by adding it
again via RowInsertCommand
.- Since:
- 1.6
-
Constructor Summary
ConstructorsConstructorDescriptionRowDeleteDataChange
(int rowIndex, Object value) Create aRowDeleteDataChange
that is able to revert the performed row delete operation. -
Method Summary
Modifier and TypeMethodDescriptionvoid
discard
(DataChangeLayer layer) Discard the change.getKey()
protected Object
getValue()
void
save
(DataChangeLayer layer) Save the change.void
Update the locally stored key.
-
Constructor Details
-
RowDeleteDataChange
Create aRowDeleteDataChange
that is able to revert the performed row delete operation.- Parameters:
rowIndex
- The row index at which the row should be inserted again.value
- The row object that should be inserted again.
-
-
Method Details
-
discard
Description copied from interface:DataChange
Discard the change.- Specified by:
discard
in interfaceDataChange
- Parameters:
layer
- TheDataChangeLayer
used to perform index-position transformations and to trigger the necessary commands to save.
-
save
Description copied from interface:DataChange
Save the change.- Specified by:
save
in interfaceDataChange
- Parameters:
layer
- TheDataChangeLayer
used to perform index-position transformations and to trigger the necessary commands to save.
-
getKey
- Specified by:
getKey
in interfaceDataChange
- Returns:
- The key used to identify the change in the backing data.
-
updateKey
Description copied from interface:DataChange
Update the locally stored key. Used in case the key changed because of structural changes.- Specified by:
updateKey
in interfaceDataChange
- Parameters:
key
- The updated key.
-
getValue
- Returns:
- The row object that was deleted.
-