Table of Contents

Class CompositeCommand

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

Combines multiple IUndoCommands into a single atomic transaction.

public class CompositeCommand : SimpleCommand, IUndoCommand
Inheritance
object
CompositeCommand
Implements
Inherited Members
Extension Methods

Constructors

CompositeCommand(params IUndoCommand[])

Combines multiple IUndoCommands into a single atomic transaction.

public CompositeCommand(params IUndoCommand[] commands)

Parameters

commands IUndoCommand[]

The commands to be contained inside the transaction.

Properties

Commands

The commands contained inside the transaction.

public IReadOnlyList<IUndoCommand> Commands { get; }

Property Value

IReadOnlyList<IUndoCommand>

Methods

OnExecute()

Executes all the contained IUndoCommands in order.

protected override void OnExecute()

OnUndo()

Undoes all the contained IUndoCommands in reverse order.

protected override void OnUndo()