com.altair.hwm.toolkit.beans
Class HWMTransferableBeanInfo

java.lang.Object
  extended by com.altair.hwm.toolkit.beans.HWMTransferableBeanInfo
All Implemented Interfaces:
java.awt.datatransfer.Transferable

public class HWMTransferableBeanInfo
extends java.lang.Object
implements java.awt.datatransfer.Transferable

Title: HWMBeanTransferableBeanInfo

Description: This object is created for each bean that is found. Used for transferring the BeanInfo from the HWMBeanMgr class to the page bean.

Company: Altair Engineering, Inc.


Field Summary
static java.awt.datatransfer.DataFlavor s_dataFlavorHWMBeanInfo
          The flavor that this transferable class supports
 
Constructor Summary
HWMTransferableBeanInfo(HWMBeanInfo hwmBeanInfo)
          Constructor
 
Method Summary
 boolean equals(java.awt.datatransfer.Transferable transferableData)
          Checks if the transferable data belongs to this class
 java.lang.Object getTransferData(java.awt.datatransfer.DataFlavor dataFlavor)
          Returns the data that needs to be transferred i.e.
 java.awt.datatransfer.DataFlavor[] getTransferDataFlavors()
          Returns all the flavors that this class supports
 boolean isDataFlavorSupported(java.awt.datatransfer.DataFlavor dataFlavor)
          Returns true if the given falvor is supported else false
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

s_dataFlavorHWMBeanInfo

public static java.awt.datatransfer.DataFlavor s_dataFlavorHWMBeanInfo
The flavor that this transferable class supports

Constructor Detail

HWMTransferableBeanInfo

public HWMTransferableBeanInfo(HWMBeanInfo hwmBeanInfo)
Constructor

Parameters:
hwmBeanInfo - The actual data that needs to be transferred to the drop target
Method Detail

equals

public boolean equals(java.awt.datatransfer.Transferable transferableData)
Checks if the transferable data belongs to this class

Parameters:
transferableData - The instance of the transferable class that a drop target receives.
Returns:
boolean true if the transferableData is an instance of this class else false.

getTransferDataFlavors

public java.awt.datatransfer.DataFlavor[] getTransferDataFlavors()
Returns all the flavors that this class supports

Specified by:
getTransferDataFlavors in interface java.awt.datatransfer.Transferable
Returns:
DataFlavor[] The list of flavors that this class supports

isDataFlavorSupported

public boolean isDataFlavorSupported(java.awt.datatransfer.DataFlavor dataFlavor)
Returns true if the given falvor is supported else false

Specified by:
isDataFlavorSupported in interface java.awt.datatransfer.Transferable
Parameters:
dataFlavor - The flavor that needs to be checked with the list of supported falvors
Returns:
boolean true if dataFlavor is supported else false

getTransferData

public java.lang.Object getTransferData(java.awt.datatransfer.DataFlavor dataFlavor)
                                 throws java.awt.datatransfer.UnsupportedFlavorException,
                                        java.io.IOException
Returns the data that needs to be transferred i.e. HWMBeanInfo as the given flavor.

Specified by:
getTransferData in interface java.awt.datatransfer.Transferable
Parameters:
dataFlavor - The flavor that the data should be passed in
Returns:
Object The data tat needs to be transferred. It is returned in the flavor that was requested
Throws:
java.awt.datatransfer.UnsupportedFlavorException
java.io.IOException