JHotDraw 6.0b1

org.jhotdraw.standard
Class CutCommand

java.lang.Object
  extended by org.jhotdraw.standard.AbstractCommand
      extended by org.jhotdraw.standard.FigureTransferCommand
          extended by org.jhotdraw.standard.CutCommand
All Implemented Interfaces:
FigureSelectionListener, Command

public class CutCommand
extends FigureTransferCommand

Delete the selection and move the selected figures to the clipboard.

See Also:
Clipboard

Nested Class Summary
static class CutCommand.UndoActivity
           
 
Nested classes/interfaces inherited from class org.jhotdraw.standard.AbstractCommand
AbstractCommand.EventDispatcher
 
Constructor Summary
CutCommand(java.lang.String name, DrawingEditor newDrawingEditor)
          Constructs a cut command.
 
Method Summary
protected  Undoable createUndoActivity()
          Factory method for undo activity
 void execute()
          Executes the command.
 boolean isExecutableWithView()
           
 
Methods inherited from class org.jhotdraw.standard.FigureTransferCommand
copyFigures, deleteFigures, insertFigures
 
Methods inherited from class org.jhotdraw.standard.AbstractCommand
addCommandListener, createEventDispatcher, createViewChangeListener, dispose, figureSelectionChanged, getDrawingEditor, getEventDispatcher, getUndoActivity, isExecutable, isViewRequired, name, removeCommandListener, setName, setUndoActivity, view, viewCreated, viewDestroying, viewSelectionChanged
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

CutCommand

public CutCommand(java.lang.String name,
                  DrawingEditor newDrawingEditor)
Constructs a cut command.

Parameters:
name - the command name
newDrawingEditor - the DrawingEditor which manages the views
Method Detail

execute

public void execute()
Description copied from class: AbstractCommand
Executes the command.

Specified by:
execute in interface Command
Overrides:
execute in class AbstractCommand
See Also:
Command.execute()

isExecutableWithView

public boolean isExecutableWithView()
Overrides:
isExecutableWithView in class AbstractCommand
See Also:
AbstractCommand.isExecutableWithView()

createUndoActivity

protected Undoable createUndoActivity()
Factory method for undo activity

Returns:
Undoable

JHotDraw 6.0b1