|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectmauda.undoredo.UndoRedo
public class UndoRedo
Stores copies of the current data-structure (e.g. FibHeap), so that it is possible to quickly undo/redo operations. If a animated redo needed, please use AnimatedUndoRedo.
| Constructor Summary | |
|---|---|
UndoRedo(Exercise exercise)
Creates a UndoRedo-Handler. |
|
| Method Summary | |
|---|---|
boolean |
canBack()
Check if a step back is possible |
boolean |
canForward()
Check if a step forward is possible |
boolean |
canRedo()
Check if a redo is possible |
boolean |
canUndo()
Check if an undo is possible |
void |
clear()
Clears all entries in the undo-redo-queue |
void |
exerciseUpdate(ExerciseUpdateEvent e)
Invoked when an Event occures |
java.lang.Object |
getDSObject()
Method for retrieving the current data-structure-object, |
java.lang.Object |
getEntry(int offset)
Methode for retrieving a specific data-structure-object |
int |
getRedoJumpDelta()
Returns the new delta-positoin to jump to, when the next action should be a redo. |
int |
getUndoJumpDelta()
Returns the new delta-position to jump to, when the next action should be an undo. |
void |
initialSnapshot(java.lang.Object o)
Creates a snapshot for a given operation. |
java.lang.String |
toString()
|
| Methods inherited from class java.lang.Object |
|---|
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Constructor Detail |
|---|
public UndoRedo(Exercise exercise)
exercise - The Exercise| Method Detail |
|---|
public void exerciseUpdate(ExerciseUpdateEvent e)
ExerciseUpdateListener
exerciseUpdate in interface ExerciseUpdateListenere - The eventpublic void initialSnapshot(java.lang.Object o)
o - generally deliver nullpublic boolean canBack()
public boolean canForward()
public boolean canUndo()
public boolean canRedo()
public int getUndoJumpDelta()
public int getRedoJumpDelta()
public void clear()
public java.lang.Object getDSObject()
public java.lang.String toString()
toString in class java.lang.Objectpublic java.lang.Object getEntry(int offset)
offset - The offset inside the undo-redo-queue
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||