Class TLcdUndoHistory

java.lang.Object
com.luciad.gui.TLcdUndoHistory

public class TLcdUndoHistory extends Object
Deprecated.
This class has no more use. Please use the new mechanism based on ILcdUndoable and TLcdUndoManager.
This is an utility class to help making an ILcdUndoable that can perform undo/redo operations. It keeps a list of Objects that represents a sequence of actions done by an ILcdUndoable. Each Object is supposed to contains the information the ILcdUndoable needs to keep in order to perform an undo or redo. The call of undo(ILcdFunction), respectively redo(ILcdFunction), will retrieve the corresponding Object and apply on it the given ILcdFunction. This ILcdFunction has to be given by the ILcdUndobale and shall effectively performs the undo, respectively redo, action. This class keep track of the number of undo and redo left.
See Also:
  • Constructor Summary

    Constructors
    Constructor
    Description
    Deprecated.
    Construct an empty TLcdUndoHistory.
  • Method Summary

    Modifier and Type
    Method
    Description
    void
    addElement(Object aObject)
    Deprecated.
    Appends to this list an Object supposed to stored the information corresponding to an action done by an ILcdUndoable and that may need undo/redo.
    void
    Deprecated.
    Adds a PropertyChangeListener to the listener list.
    protected void
    firePropertyChange(String propertyName, Object oldValue, Object newValue)
    Deprecated.
     
    int
    Deprecated.
    Returns the number of redo operations that can still be performed.
    int
    Deprecated.
    Returns the number of undo operations that can still be performed.
    void
    redo(ILcdFunction aRedoFunction)
    Deprecated.
    Performs a redo by retrieving the corresponding Object, and applying the given ILcdFunction.
    void
    Deprecated.
    Removes all the Objects supposed to stored the information required by an ILcdUndoable to perform undo and redo operations.
    void
    Deprecated.
    Removes a PropertyChangeListener from the listener list.
    void
    undo(ILcdFunction aUndoFunction)
    Deprecated.
    Performs an undo by retrieving the corresponding Object, and applying the given ILcdFunction.

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • Constructor Details

    • TLcdUndoHistory

      public TLcdUndoHistory()
      Deprecated.
      Construct an empty TLcdUndoHistory.
  • Method Details

    • getUndoLeft

      public int getUndoLeft()
      Deprecated.
      Returns the number of undo operations that can still be performed.
    • getRedoLeft

      public int getRedoLeft()
      Deprecated.
      Returns the number of redo operations that can still be performed.
    • addElement

      public void addElement(Object aObject)
      Deprecated.
      Appends to this list an Object supposed to stored the information corresponding to an action done by an ILcdUndoable and that may need undo/redo. This Object can be used later by this ILcdUndoable in order to perform the undo or redo operation.
    • removeAllElements

      public void removeAllElements()
      Deprecated.
      Removes all the Objects supposed to stored the information required by an ILcdUndoable to perform undo and redo operations.
    • undo

      public void undo(ILcdFunction aUndoFunction)
      Deprecated.
      Performs an undo by retrieving the corresponding Object, and applying the given ILcdFunction. It decrements the number of remaining undo.
    • redo

      public void redo(ILcdFunction aRedoFunction)
      Deprecated.
      Performs a redo by retrieving the corresponding Object, and applying the given ILcdFunction. It decrements the number of remaining redo.
    • firePropertyChange

      protected void firePropertyChange(String propertyName, Object oldValue, Object newValue)
      Deprecated.
    • addPropertyChangeListener

      public void addPropertyChangeListener(PropertyChangeListener aListener)
      Deprecated.
      Adds a PropertyChangeListener to the listener list. The listener is registered for all properties.
      Parameters:
      aListener - the PropertyChangeListener to be added.
    • removePropertyChangeListener

      public void removePropertyChangeListener(PropertyChangeListener aListener)
      Deprecated.
      Removes a PropertyChangeListener from the listener list. This removes a PropertyChangeListener that was registered for all properties.
      Parameters:
      aListener - the PropertyChangeListener to be removed.