public class WorkflowDropTargetContextPeer
extends java.lang.Object
implements java.awt.dnd.peer.DropTargetContextPeer
Constructor and Description |
---|
WorkflowDropTargetContextPeer(java.awt.dnd.DropTarget target,
java.awt.datatransfer.Transferable t)
Constructs the WorkflowDropTargetContextPeer
|
Modifier and Type | Method and Description |
---|---|
void |
acceptDrag(int dragAction)
Called to accept the drag
|
void |
acceptDrop(int dropAction)
Called to accept the drop
|
void |
dropComplete(boolean success)
Signal that the drop is complete
|
java.awt.dnd.DropTarget |
getDropTarget()
Gets the DropTarget associated with this peer
|
int |
getTargetActions()
Gets the current Target actions
|
java.awt.datatransfer.Transferable |
getTransferable()
Gets the transferable
|
java.awt.datatransfer.DataFlavor[] |
getTransferDataFlavors()
Gets the (remote) DataFlavors from the peer
|
boolean |
isTransferableJVMLocal()
Returns whether or not the transferable is in the same
JVM as the target.
|
void |
rejectDrag()
Called to reject the drag
|
void |
rejectDrop()
Called to reject the drop
|
void |
setTargetActions(int actions)
Update the peer's notion of the Target's actions
|
public WorkflowDropTargetContextPeer(java.awt.dnd.DropTarget target, java.awt.datatransfer.Transferable t)
target
- The current drop targett
- The transferablepublic void setTargetActions(int actions)
setTargetActions
in interface java.awt.dnd.peer.DropTargetContextPeer
actions
- The target actionspublic int getTargetActions()
getTargetActions
in interface java.awt.dnd.peer.DropTargetContextPeer
public java.awt.dnd.DropTarget getDropTarget()
getDropTarget
in interface java.awt.dnd.peer.DropTargetContextPeer
public java.awt.datatransfer.DataFlavor[] getTransferDataFlavors()
getTransferDataFlavors
in interface java.awt.dnd.peer.DropTargetContextPeer
public java.awt.datatransfer.Transferable getTransferable() throws java.awt.dnd.InvalidDnDOperationException
getTransferable
in interface java.awt.dnd.peer.DropTargetContextPeer
java.awt.dnd.InvalidDnDOperationException
public boolean isTransferableJVMLocal()
isTransferableJVMLocal
in interface java.awt.dnd.peer.DropTargetContextPeer
public void acceptDrag(int dragAction)
acceptDrag
in interface java.awt.dnd.peer.DropTargetContextPeer
public void rejectDrag()
rejectDrag
in interface java.awt.dnd.peer.DropTargetContextPeer
public void acceptDrop(int dropAction)
acceptDrop
in interface java.awt.dnd.peer.DropTargetContextPeer
public void rejectDrop()
rejectDrop
in interface java.awt.dnd.peer.DropTargetContextPeer
public void dropComplete(boolean success)
dropComplete
in interface java.awt.dnd.peer.DropTargetContextPeer
success
- True if successful false if not