dsto.dfc.swing.undo
Class CmdUndoTo

java.lang.Object
  extended by dsto.dfc.swing.commands.AbstractCommand
      extended by dsto.dfc.swing.commands.AbstractMutableCommand
          extended by dsto.dfc.swing.undo.AbstractUndoableCommand
              extended by dsto.dfc.swing.undo.CmdUndo
                  extended by dsto.dfc.swing.undo.CmdUndoTo
All Implemented Interfaces:
Command, Iconic, EditExceptionPolicy, Copyable, PropertyEventSource, ActionListener, Cloneable, EventListener

public class CmdUndoTo
extends CmdUndo

Command to invoke undoTo () on a MonitoredUndoManager.

Version:
$Revision$
Author:
Derek Weber, Peter J Smet

Field Summary
 
Fields inherited from class dsto.dfc.swing.undo.CmdUndo
ICON
 
Fields inherited from class dsto.dfc.swing.undo.AbstractUndoableCommand
cursorUpdatePolicy, exceptionHandler, name, undoManager
 
Fields inherited from class dsto.dfc.swing.commands.AbstractMutableCommand
listeners
 
Fields inherited from class dsto.dfc.swing.commands.AbstractCommand
displayName, icon
 
Fields inherited from interface dsto.dfc.swing.icons.Iconic
NULL_ICON
 
Constructor Summary
CmdUndoTo(EditListView editListView, MonitoredUndoManager undoManager)
           
 
Method Summary
 String getDescription()
          A short description of the command, suitable for a tooltip or use in a status panel.
protected  void listenForEnablingEvents()
          Start listening for enabling cursor changes.
 UndoableEdit selectedEdit()
          Returns the undo cursor.
 void skip()
          Skips the edit causing the exception and continues undoing, but checks to see if the exception-causing edit is the last to be undone - if so it stops.
protected  void stopListeningForEnablingEvents()
          Stop listening for enabling cursor changes.
 
Methods inherited from class dsto.dfc.swing.undo.CmdUndo
execute, getAccelerator, getIcon, getMnemonic, updateEnabled
 
Methods inherited from class dsto.dfc.swing.undo.AbstractUndoableCommand
execute, getGroupInView, getName, handleNonExecutableEdit, isInteractive, listenForEnablingEvents, pause, retry
 
Methods inherited from class dsto.dfc.swing.commands.AbstractMutableCommand
addPropertyChangeListener, clone, isEnabled, removePropertyChangeListener, setEnabled, setIcon
 
Methods inherited from class dsto.dfc.swing.commands.AbstractCommand
actionPerformed, canReplace, getDefaultDisplayName, getDisplayName, getLargeIcon, getLogString, setDisplayName
 
Methods inherited from class java.lang.Object
equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

CmdUndoTo

public CmdUndoTo(EditListView editListView,
                 MonitoredUndoManager undoManager)
Method Detail

getDescription

public String getDescription()
Description copied from interface: Command
A short description of the command, suitable for a tooltip or use in a status panel.

Specified by:
getDescription in interface Command
Overrides:
getDescription in class CmdUndo

selectedEdit

public UndoableEdit selectedEdit()
Description copied from class: CmdUndo
Returns the undo cursor.

Overrides:
selectedEdit in class CmdUndo

skip

public void skip()
Skips the edit causing the exception and continues undoing, but checks to see if the exception-causing edit is the last to be undone - if so it stops.

Specified by:
skip in interface EditExceptionPolicy
Overrides:
skip in class CmdUndo

listenForEnablingEvents

protected void listenForEnablingEvents()
Description copied from class: AbstractUndoableCommand
Start listening for enabling cursor changes.

Overrides:
listenForEnablingEvents in class AbstractUndoableCommand

stopListeningForEnablingEvents

protected void stopListeningForEnablingEvents()
Description copied from class: AbstractUndoableCommand
Stop listening for enabling cursor changes.

Overrides:
stopListeningForEnablingEvents in class AbstractUndoableCommand


Copyright © 2008 Commonwealth of Australia