Click or drag to resize

IUndoRedoManagerT Interface

Represents the interface that provides functionalities for managing undo and redo processes.

Namespace: RAYLASE.Marker.UndoRedo
Assembly: RAYLASE.Marker.UndoRedo (in RAYLASE.Marker.UndoRedo.dll) Version: 2.19.0
Syntax
C#
public interface IUndoRedoManager<T> : IDisposable

Type Parameters

T

The IUndoRedoManagerT type exposes the following members.

Properties
 NameDescription
Public propertyCanRedo Checks if there are any stored state available on the redo stack.
Public propertyCanUndo Checks if there are any stored state available on the undo stack.
Public propertyInUndoRedo Gets a value indicating if the history is in the process of undoing or redoing.
Public propertyMementoSizeThreshold The size threshold that a memento can be added to the stack. A non-positive value means no size limit. The size is just an arbitrary value.
Public propertyRedoCount Gets number of redo actions available
Public propertyStackPermissionType The flag to indicate how a memento is added to the stack.
Public propertySubject The subject that this undo redo history is about.
Public propertySupportRedo Gets or sets whether the history supports redo.
Public propertyUndoCount Gets number of undo actions available
Public propertyValidator The delegate to ask for confirmation when a memento is added. A null validator means that the memento is always approved.
Top
Methods
 NameDescription
Public methodClear Clear the entire undo and redo stacks.
Public methodCompoundDo Pushes mementos into the undo stack, any time the state of Subject changes.
Public methodDo(IListIMementoT) Pushes mementos into the undo stack, any time the state of Subject changes.
Public methodDo(IMementoT) Pushes an memento into the undo stack, any time the state of Subject changes.
Public methodPeekRedo Gets, without removing, the top memento on the redo stack.
Public methodPeekUndo Gets, without removing, the top memento on the undo stack.
Public methodRedo Restores the subject to the next state on the redo stack, and stores the state before redoing to undo stack. Method CanRedo can be called before calling this method.
Public methodUndo Restores the subject to the previous state on the undo stack, and stores the state before undoing to redo stack. Method CanUndo can be called before calling this method.
Top
Events
 NameDescription
Public eventStackChanged Raised whenever there is a change to the undo-redo stack.
Top
See Also