JHotDraw 7rev733

org.jhotdraw.draw.event
Class CompositeFigureEdit

java.lang.Object
  extended by javax.swing.undo.AbstractUndoableEdit
      extended by javax.swing.undo.CompoundEdit
          extended by org.jhotdraw.undo.CompositeEdit
              extended by org.jhotdraw.draw.event.CompositeFigureEdit
All Implemented Interfaces:
java.io.Serializable, javax.swing.undo.UndoableEdit

public class CompositeFigureEdit
extends CompositeEdit

A CompositeEdit which invokes figure.willChange and figure.changed when undoing or redoing a change.

Version:
$Id: CompositeFigureEdit.java 717 2010-11-21 12:30:57Z rawcoder $
Author:
Werner Randelshofer
See Also:
Serialized Form

Field Summary
 
Fields inherited from class javax.swing.undo.CompoundEdit
edits
 
Fields inherited from class javax.swing.undo.AbstractUndoableEdit
RedoName, UndoName
 
Constructor Summary
CompositeFigureEdit(Figure figure)
          Creates a new CompositeFigureEdit which uses CompoundEdit.getPresentatioName and is significant.
CompositeFigureEdit(Figure figure, boolean isSignificant)
          Creates new CompositeFigureEdit which uses the specified significance.
CompositeFigureEdit(Figure figure, java.lang.String presentationName)
          Creates new CompositeFigureEdit which uses the specified presentation name.
CompositeFigureEdit(Figure figure, java.lang.String presentationName, boolean isSignificant)
          Creates new CompositeEdit.
 
Method Summary
 void redo()
           
 void undo()
           
 
Methods inherited from class org.jhotdraw.undo.CompositeEdit
addEdit, getPresentationName, getRedoPresentationName, getUndoPresentationName, isSignificant, setSignificant, setVerbose
 
Methods inherited from class javax.swing.undo.CompoundEdit
canRedo, canUndo, die, end, isInProgress, lastEdit, toString
 
Methods inherited from class javax.swing.undo.AbstractUndoableEdit
replaceEdit
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

CompositeFigureEdit

public CompositeFigureEdit(Figure figure)
Creates a new CompositeFigureEdit which uses CompoundEdit.getPresentatioName and is significant.

See Also:
CompoundEdit.getPresentationName()

CompositeFigureEdit

public CompositeFigureEdit(Figure figure,
                           boolean isSignificant)
Creates new CompositeFigureEdit which uses the specified significance.

See Also:
CompoundEdit.getPresentationName()

CompositeFigureEdit

public CompositeFigureEdit(Figure figure,
                           java.lang.String presentationName)
Creates new CompositeFigureEdit which uses the specified presentation name.

See Also:
CompoundEdit.getPresentationName()

CompositeFigureEdit

public CompositeFigureEdit(Figure figure,
                           java.lang.String presentationName,
                           boolean isSignificant)
Creates new CompositeEdit. Which uses the given presentation name. If the presentation name is null, then CompoundEdit.getPresentatioName is used.

See Also:
CompoundEdit.getPresentationName()
Method Detail

undo

public void undo()
Specified by:
undo in interface javax.swing.undo.UndoableEdit
Overrides:
undo in class javax.swing.undo.CompoundEdit

redo

public void redo()
Specified by:
redo in interface javax.swing.undo.UndoableEdit
Overrides:
redo in class javax.swing.undo.CompoundEdit

Copyright 1996-2010 (c) by the authors and contributors of the JHotDraw project.
Some rights reserved.