dsto.dfc.swt.dnd
Class CmdCopyDataObjectProperties

java.lang.Object
  extended by dsto.dfc.util.BasicPropertyEventSource
      extended by dsto.dfc.swt.commands.AbstractCommand
          extended by dsto.dfc.swt.commands.AbstractCopyCommand
              extended by dsto.dfc.swt.dnd.CmdCopyObject
                  extended by dsto.dfc.swt.dnd.CmdCopyDataObjectProperties
All Implemented Interfaces:
Command, Copyable, JavaBean, PropertyEventSource, Serializable, Cloneable

public class CmdCopyDataObjectProperties
extends CmdCopyObject

Command that copies selected properties of an IDataObject to the clipboard as text.

Author:
Matthew Phillips
See Also:
Serialized Form

Field Summary
 
Fields inherited from class dsto.dfc.swt.dnd.CmdCopyObject
object, transferFormats
 
Fields inherited from class dsto.dfc.swt.commands.AbstractCommand
NO_ICON
 
Constructor Summary
CmdCopyDataObjectProperties(IDataObject dataObject)
          Create a new instance copying properties from a given data object.
 
Method Summary
protected  Object[] createTransferData()
          Create the data to be transferred when the command is executed.
 String[] getProperties()
           
 void setProperties(String[] properties)
          Set the names of the properties of the current data object that will be copied when command is executed.
 
Methods inherited from class dsto.dfc.swt.dnd.CmdCopyObject
execute, getObject, setObject, setTransferFormat, setTransferFormats
 
Methods inherited from class dsto.dfc.swt.commands.AbstractCommand
addCommandListener, clone, createDefaultDisplayName, fireCommandExecuted, fireCommandExecuted, getAccelerator, getContextMenuGroup, getDescription, getDisplayName, getGroupInView, getIcon, getLogString, getMainMenuGroup, getMnemonic, getName, getToolbarGroup, isEnabled, isInteractive, removeCommandListener, setAccelerator, setContextMenuGroup, setDescription, setDisplayName, setEnabled, setIcon, setInteractive, setMainMenuGroup, setMnemonic, setName, setToolbarGroup
 
Methods inherited from class dsto.dfc.util.BasicPropertyEventSource
addPropertyChangeListener, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, getPropertyChangeSource, removePropertyChangeListener, setPropertyChangeSource
 
Methods inherited from class java.lang.Object
equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface dsto.dfc.util.PropertyEventSource
addPropertyChangeListener, removePropertyChangeListener
 

Constructor Detail

CmdCopyDataObjectProperties

public CmdCopyDataObjectProperties(IDataObject dataObject)
Create a new instance copying properties from a given data object.

Method Detail

getProperties

public String[] getProperties()

setProperties

public void setProperties(String[] properties)
Set the names of the properties of the current data object that will be copied when command is executed.

Parameters:
properties - The properties copy. May be null.

createTransferData

protected Object[] createTransferData()
Description copied from class: CmdCopyObject
Create the data to be transferred when the command is executed. The default is to simply wrap object in an array. Subclasses may override to generate data at execution time.

Overrides:
createTransferData in class CmdCopyObject


Copyright © 2008 Commonwealth of Australia