Class DelegateCommandManager<C,V>
- java.lang.Object
-
- org.kie.workbench.common.command.client.DelegateCommandManager<C,V>
-
- All Implemented Interfaces:
CommandManager<C,V>
public abstract class DelegateCommandManager<C,V> extends Object implements CommandManager<C,V>
-
-
Constructor Summary
Constructors Constructor Description DelegateCommandManager()
-
Method Summary
All Methods Instance Methods Abstract Methods Concrete Methods Modifier and Type Method Description CommandResult<V>allow(C context, Command<C,V> command)Check whether the given command can be executed.CommandResult<V>execute(C context, Command<C,V> command)Execute the given command.protected abstract CommandManager<C,V>getDelegate()protected voidpostAllow(C context, Command<C,V> command, CommandResult<V> result)protected voidpostExecute(C context, Command<C,V> command, CommandResult<V> result)protected voidpostUndo(C context, Command<C,V> command, CommandResult<V> result)protected voidpreAllow(C context, Command<C,V> command)protected voidpreExecute(C context, Command<C,V> command)protected voidpreUndo(C context, Command<C,V> command)CommandResult<V>undo(C context, Command<C,V> command)Undo an executed command.
-
-
-
Method Detail
-
getDelegate
protected abstract CommandManager<C,V> getDelegate()
-
allow
public CommandResult<V> allow(C context, Command<C,V> command)
Description copied from interface:CommandManagerCheck whether the given command can be executed.- Specified by:
allowin interfaceCommandManager<C,V>
-
execute
public CommandResult<V> execute(C context, Command<C,V> command)
Description copied from interface:CommandManagerExecute the given command.- Specified by:
executein interfaceCommandManager<C,V>
-
undo
public CommandResult<V> undo(C context, Command<C,V> command)
Description copied from interface:CommandManagerUndo an executed command.- Specified by:
undoin interfaceCommandManager<C,V>
-
-