C - the type of change to undo/redoUndoManager<C>MultiChangeUndoManagerImplpublic class UndoManagerImpl<C> extends java.lang.Object implements UndoManager<C>
UndoManager for single changes. For multiple changes, see
MultiChangeUndoManagerImpl.| Type | Property | Description |
|---|---|---|
javafx.beans.value.ObservableBooleanValue |
atMarkedPosition |
Indicates whether this UndoManager's current position within
its history is the same as the last marked position.
|
org.reactfx.value.Val<C> |
nextRedo |
Gives a peek at the change that will be redone by
UndoManager.redo(). |
org.reactfx.value.Val<C> |
nextUndo |
Gives a peek at the change that will be undone by
UndoManager.undo(). |
javafx.beans.value.ObservableBooleanValue |
performingAction |
Indicates whether this undo manager is currently performing undo or redo
action.
|
org.reactfx.value.Val<java.lang.Boolean> |
redoAvailable |
Indicates whether there is a change that can be redone.
|
org.reactfx.value.Val<java.lang.Boolean> |
undoAvailable |
Indicates whether there is a change that can be undone.
|
UndoManager.UndoPosition| Constructor | Description |
|---|---|
UndoManagerImpl(ChangeQueue<C> queue,
java.util.function.Function<? super C,? extends C> invert,
java.util.function.Consumer<C> apply,
java.util.function.BiFunction<C,C,java.util.Optional<C>> merge,
java.util.function.Predicate<C> isIdentity,
org.reactfx.EventStream<C> changeSource) |
|
UndoManagerImpl(ChangeQueue<C> queue,
java.util.function.Function<? super C,? extends C> invert,
java.util.function.Consumer<C> apply,
java.util.function.BiFunction<C,C,java.util.Optional<C>> merge,
java.util.function.Predicate<C> isIdentity,
org.reactfx.EventStream<C> changeSource,
java.time.Duration preventMergeDelay) |
| Modifier and Type | Method | Description |
|---|---|---|
javafx.beans.value.ObservableBooleanValue |
atMarkedPositionProperty() |
Indicates whether this UndoManager's current position within
its history is the same as the last marked position.
|
void |
close() |
Stops observing change events.
|
void |
forgetHistory() |
Forgets all changes prior to the current position in the history.
|
UndoManager.UndoPosition |
getCurrentPosition() |
Returns the current position within this UndoManager's history.
|
boolean |
isAtMarkedPosition() |
|
boolean |
isPerformingAction() |
|
boolean |
isRedoAvailable() |
|
boolean |
isUndoAvailable() |
|
org.reactfx.value.Val<C> |
nextRedoProperty() |
Gives a peek at the change that will be redone by
UndoManager.redo(). |
org.reactfx.value.Val<C> |
nextUndoProperty() |
Gives a peek at the change that will be undone by
UndoManager.undo(). |
javafx.beans.value.ObservableBooleanValue |
performingActionProperty() |
Indicates whether this undo manager is currently performing undo or redo
action.
|
void |
preventMerge() |
Prevents the next change from being merged with the latest one.
|
boolean |
redo() |
Redo previously undone change, if there is any change to redo.
|
org.reactfx.value.Val<java.lang.Boolean> |
redoAvailableProperty() |
Indicates whether there is a change that can be redone.
|
boolean |
undo() |
Undo the most recent change, if there is any change to undo.
|
org.reactfx.value.Val<java.lang.Boolean> |
undoAvailableProperty() |
Indicates whether there is a change that can be undone.
|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitgetNextRedo, getNextUndo, markpublic org.reactfx.value.Val<C> nextUndoProperty
nextUndoProperty in interface UndoManager<C>public org.reactfx.value.Val<C> nextRedoProperty
nextRedoProperty in interface UndoManager<C>public org.reactfx.value.Val<java.lang.Boolean> undoAvailableProperty
undoAvailableProperty in interface UndoManager<C>public org.reactfx.value.Val<java.lang.Boolean> redoAvailableProperty
redoAvailableProperty in interface UndoManager<C>public javafx.beans.value.ObservableBooleanValue performingActionProperty
performingActionProperty in interface UndoManager<C>public javafx.beans.value.ObservableBooleanValue atMarkedPositionProperty
atMarkedPositionProperty in interface UndoManager<C>public UndoManagerImpl(ChangeQueue<C> queue, java.util.function.Function<? super C,? extends C> invert, java.util.function.Consumer<C> apply, java.util.function.BiFunction<C,C,java.util.Optional<C>> merge, java.util.function.Predicate<C> isIdentity, org.reactfx.EventStream<C> changeSource)
public UndoManagerImpl(ChangeQueue<C> queue, java.util.function.Function<? super C,? extends C> invert, java.util.function.Consumer<C> apply, java.util.function.BiFunction<C,C,java.util.Optional<C>> merge, java.util.function.Predicate<C> isIdentity, org.reactfx.EventStream<C> changeSource, java.time.Duration preventMergeDelay)
public void close()
UndoManagerclose in interface UndoManager<C>public boolean undo()
UndoManagerundo in interface UndoManager<C>true if a change was undone, false otherwise.public boolean redo()
UndoManagerredo in interface UndoManager<C>true if a change was redone, false otherwise.public org.reactfx.value.Val<C> nextUndoProperty()
UndoManagerUndoManager.undo().nextUndoProperty in interface UndoManager<C>public org.reactfx.value.Val<C> nextRedoProperty()
UndoManagerUndoManager.redo().nextRedoProperty in interface UndoManager<C>public boolean isUndoAvailable()
isUndoAvailable in interface UndoManager<C>public org.reactfx.value.Val<java.lang.Boolean> undoAvailableProperty()
UndoManagerundoAvailableProperty in interface UndoManager<C>public boolean isRedoAvailable()
isRedoAvailable in interface UndoManager<C>public org.reactfx.value.Val<java.lang.Boolean> redoAvailableProperty()
UndoManagerredoAvailableProperty in interface UndoManager<C>public boolean isPerformingAction()
isPerformingAction in interface UndoManager<C>public javafx.beans.value.ObservableBooleanValue performingActionProperty()
UndoManagerperformingActionProperty in interface UndoManager<C>public boolean isAtMarkedPosition()
isAtMarkedPosition in interface UndoManager<C>public javafx.beans.value.ObservableBooleanValue atMarkedPositionProperty()
UndoManageratMarkedPositionProperty in interface UndoManager<C>public UndoManager.UndoPosition getCurrentPosition()
UndoManagergetCurrentPosition in interface UndoManager<C>public void preventMerge()
UndoManagerpreventMerge in interface UndoManager<C>public void forgetHistory()
UndoManagerforgetHistory in interface UndoManager<C>