public interface IDelete
Modifier and Type | Method and Description |
---|---|
boolean |
canDelete(IDeleteContext context)
Can delete hook.
|
void |
delete(IDeleteContext context)
Hook to implement the actual delete functionality.
|
boolean |
isDeleteAbort()
The Graphiti framework will call this method after
preDelete(IDeleteContext) has been called and before the actual
delete is done. |
void |
postDelete(IDeleteContext context)
Post delete hook that can be implemented by users to perform any
operations that need to be done after the standard delete functionality
ends.
|
void |
preDelete(IDeleteContext context)
Pre delete hook that can be implemented by users to perform any
operations that need to be done before the standard delete functionality
starts.
|
boolean canDelete(IDeleteContext context)
context
- the context describing the requesttrue
, if the feature can perform the delete
operationvoid preDelete(IDeleteContext context)
DefaultDeleteFeature#setDoneChanges(boolean)
in case you modify
any EMF objects to enable that the command stack gets updated.context
- the contextboolean isDeleteAbort()
preDelete(IDeleteContext)
has been called and before the actual
delete is done. In case this method returns true
, the
operation will be cancelled by the Graphiti framework by throwing an
OperationCanceledException
that causes am EMF revert of the
operation.
Implementing classes might e.g. set a flag in
preDelete(IDeleteContext)
as cancellation indication and check
that that flag here.
true
in case you want to cancel the current
operation, false
otherwise.void delete(IDeleteContext context)
context
- the contextvoid postDelete(IDeleteContext context)
context
- the context