org.jhotdraw.standard
Class CopyCommand

java.lang.Object
  extended byorg.jhotdraw.standard.AbstractCommand
      extended byorg.jhotdraw.standard.FigureTransferCommand
          extended byorg.jhotdraw.standard.CopyCommand
All Implemented Interfaces:
Command, FigureSelectionListener

public class CopyCommand
extends FigureTransferCommand

Copy the selection to the clipboard.

Version:
<$CURRENT_VERSION$>
See Also:
Clipboard

Nested Class Summary
 
Nested classes inherited from class org.jhotdraw.standard.AbstractCommand
AbstractCommand.EventDispatcher
 
Constructor Summary
CopyCommand(java.lang.String name, DrawingEditor newDrawingEditor)
          Constructs a copy command.
 
Method Summary
 void execute()
          Executes the command.
protected  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

CopyCommand

public CopyCommand(java.lang.String name,
                   DrawingEditor newDrawingEditor)
Constructs a copy 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

isExecutableWithView

protected boolean isExecutableWithView()
Overrides:
isExecutableWithView in class AbstractCommand