com.apelon.beans.dts.plugin.transferable
Class DTSMultiTransferable

java.lang.Object
  extended by com.apelon.beans.dts.plugin.transferable.AbstractTransferable
      extended by com.apelon.beans.dts.plugin.transferable.DTSMultiTransferable
All Implemented Interfaces:
Transferable

public class DTSMultiTransferable
extends AbstractTransferable

For transfer of a list of DTS Objects as Vector through Drag and Drop.

It supports these data flavors:

Since:
3.3.0
Version:
DTS 3.3.0
Author:
Apelon Inc.

Constructor Summary
DTSMultiTransferable(Vector selectedItems)
          Initializes with given selectedItems.
 
Method Summary
static DataFlavor getDataFlavor()
          Deprecated. Use DTSDataFlavor.multiFlavor instead
 Object getTransferData(DataFlavor dataflavor)
          Returns the data for a given DataFlavor.
 
Methods inherited from class com.apelon.beans.dts.plugin.transferable.AbstractTransferable
createConstant, getTransferDataFlavors, isDataFlavorSupported, setTransferDataFlavors
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

DTSMultiTransferable

public DTSMultiTransferable(Vector selectedItems)
Initializes with given selectedItems. Checks every element in selectedItems and set the corresponding data flavor to the supported DataFlavors.

Method Detail

getDataFlavor

public static DataFlavor getDataFlavor()
Deprecated. Use DTSDataFlavor.multiFlavor instead

Returns DataFlavor of this Transferable

Returns:
java.awt.datatransfer.DataFlavor

getTransferData

public Object getTransferData(DataFlavor dataflavor)
Returns the data for a given DataFlavor.

For Multiple DTS Objects Data Flavor, the list (Vector) of this Transferable is returned.

For other Data Flavor, the returned value is the first item of the list.

Parameters:
dataflavor - java.awt.datatransfer.DataFlavor
Returns:
java.lang.Object


Copyright © 2011. All Rights Reserved.