Interface ICommand
- Namespace
- WitShells.DesignPatterns.Core
Defines the contract for the Command pattern. Each command encapsulates a single action and its reversal, enabling undo/redo stacks, macro recording, and deferred execution.
public interface ICommand
Methods
Execute()
Performs the command's primary action.
void Execute()
Undo()
Reverses the command's action, restoring previous state.
void Undo()