Table of Contents

Namespace NanoByte.Common.Undo

Undo system based on the Command pattern.

Classes

AddToCollection

Factory methods for AddToCollection<T>.

AddToCollection<T>

An undo command that adds an element to a collection.

CollectionCommand<T>

An undo command that adds or removes an element from a collection.

CommandCollector

Executes IUndoCommands and collects them into a CompositeCommand allowing a combined undo later on.

CommandManager

Factory methods for ICommandManager<T>.

CommandManager<T>

Executes IUndoCommands for editing a specific object and allows undo/redo operations.

CompositeCommand

Combines multiple IUndoCommands into a single atomic transaction.

ConcurrentCommandExecutor

Decorator for ICommandExecutor that adds locking for thread-safety.

FirstExecuteCommand

An undo command that does something different on the first call to Execute() than on subsequent redo calls.

MultiPropertyChangedCommand

An undo command that handles multiple changed properties - usually used with a System.Windows.Forms.PropertyGrid.

MultiPropertyTracker

Tracks values in System.Windows.Forms.PropertyGrids in order to be able to generate MultiPropertyChangedCommands after a property was changed.

PreExecutedCommand

An undo command that does nothing on the first Execute() call, because the action was already performed beforehand

PreExecutedCompositeCommand

Combines multiple already executed IUndoCommands into a single atomic transaction.

PropertyChangedCommand

An undo command that handles a changed property - usually used with a System.Windows.Forms.PropertyGrid.

RemoveFromCollection

Factory methods for RemoveFromCollection<T>.

RemoveFromCollection<T>

An undo command that removes an element from a collection.

ReplaceInList

Factory methods for ReplaceInList<T>.

ReplaceInList<T>

An undo command that replaces an element in a list with a new one.

SetInList

Factory methods for SetInList<T>.

SetInList<T>

Replaces an entry in a System.Collections.Generic.IList<T> with a new one.

SetLocalizableString

An undo command that sets a LocalizableString in a LocalizableStringCollection.

SetValueCommand

Factory methods for SetValueCommand<T>.

SetValueCommand<T>

An undo command that uses a delegates for getting and setting values from a backing model.

SimpleCommand

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

SimpleCommandExecutor

Executes IUndoCommands without any additional handling.

Interfaces

ICommandExecutor

Executes IUndoCommands.

ICommandManager<T>

Executes IUndoCommands for editing a specific object and allows undo/redo operations.

IUndoCommand

A executable command with an undo function.

IValueCommand

A command that exposes the value it will set.