Table of Contents

Class SimpleCommand

Namespace
NanoByte.Common.Undo
Assembly
NanoByte.Common.dll

An undo command that automatically tracks when Execute() and Undo() can be called.

public abstract class SimpleCommand : IUndoCommand
Inheritance
SimpleCommand
Implements
Derived
Extension Methods

Methods

Execute()

Performs the desired action.

public void Execute()

OnExecute()

Template method to perform the desired action.

protected abstract void OnExecute()

OnUndo()

Template method to undo the changes made by OnExecute().

protected abstract void OnUndo()

Undo()

Undoes the changes made by Execute().

public virtual void Undo()