Event handlers in ET++ immediately return a Command object, which
encapsulates the real work to be done. The Command is queued up for a Command
Processor object which will execute the Command by calling its
DoIt()
method. The Command Processor will also save the
Command in a history list so that it can be later undone. Commands are
undone by calling their UndoIt()
method, and redone by calling
their RedoIt()
method.
This design is an instance of the Command pattern. It ensures that no matter which part of the interface initiates a request, the request is always handled in the same way and is always undoable.
ET++ solves this problem by using the Atomizer pattern. The same solution also allows storing and transmitting arbitrary object structures.