Skip to main content

Interface: CommandBatch

Provide the means to store or discard command batch.

See

CommandHistory.startBatch

Properties

PropertyModifierTypeDescription

history

readonly

CommandHistory

Command history which owns this batch.

Methods

discard()

discard(): void

Discards the batch, throwing away all nested commands, so they cannot be undone.

This is useful when performing state changes on temporary items to avoid being able to revert it.

Returns

void

Defined in

diagram/history.ts:244


store()

store(): void

Stores the batch, combining the nested command sequence into a single revertible command.

Returns

void

Defined in

diagram/history.ts:237