java.lang.Object | |
↳ | java.awt.dnd.DropTargetContext |
A DropTargetContext
is created
whenever the logical cursor associated
with a Drag and Drop operation coincides with the visible geometry of
a Component
associated with a DropTarget
.
The DropTargetContext
provides
the mechanism for a potential receiver
of a drop operation to both provide the end user with the appropriate
drag under feedback, but also to effect the subsequent data transfer
if appropriate.
Nested Classes | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
DropTargetContext.TransferableProxy | TransferableProxy is a helper inner class that implements
Transferable interface and serves as a proxy for another
Transferable object which represents data transfer for
a particular drag-n-drop operation. |
Public Methods | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
Called when associated with the
DropTargetContextPeer . | |||||||||||
This method signals that the drop is completed and
if it was successful or not.
| |||||||||||
This method returns the
Component associated with
this DropTargetContext . | |||||||||||
This method returns the
DropTarget associated with this
DropTargetContext . | |||||||||||
Called when disassociated with the
DropTargetContextPeer . |
Protected Methods | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
accept the Drag.
| |||||||||||
called to signal that the drop is acceptable
using the specified operation.
| |||||||||||
Creates a TransferableProxy to proxy for the specified
Transferable.
| |||||||||||
get the available DataFlavors of the
Transferable operand of this operation. | |||||||||||
This method returns a the currently available DataFlavors
of the
Transferable operand
as a java.util.List . | |||||||||||
This method returns an
int representing the
current actions this DropTarget will accept. | |||||||||||
get the Transferable (proxy) operand of this operation
| |||||||||||
This method returns a
boolean
indicating if the given DataFlavor is
supported by this DropTargetContext . | |||||||||||
reject the Drag.
| |||||||||||
called to signal that the drop is unacceptable.
| |||||||||||
This method sets the current actions acceptable to
this
DropTarget . |
[Expand]
Inherited Methods | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
From class
java.lang.Object
|
Called when associated with the DropTargetContextPeer
.
dtcp | the DropTargetContextPeer
|
---|
This method signals that the drop is completed and if it was successful or not.
success | true for success, false if not |
---|
InvalidDnDOperationException | if a drop is not outstanding/extant |
---|
This method returns the Component
associated with
this DropTargetContext
.
This method returns the DropTarget
associated with this
DropTargetContext
.
DropTarget
associated with this DropTargetContext
Called when disassociated with the DropTargetContextPeer
.
accept the Drag.
dragOperation | the supported action(s) |
---|
called to signal that the drop is acceptable using the specified operation. must be called during DropTargetListener.drop method invocation.
dropOperation | the supported action(s) |
---|
Creates a TransferableProxy to proxy for the specified Transferable.
t | the Transferable to be proxied |
---|---|
local | true if t represents the result of a local drag-n-drop operation. |
get the available DataFlavors of the
Transferable
operand of this operation.
DataFlavor[]
containing the
supported DataFlavor
s of the
Transferable
operand.
This method returns a the currently available DataFlavors
of the Transferable
operand
as a java.util.List
.
java.util.List
This method returns an int
representing the
current actions this DropTarget
will accept.
DropTarget
get the Transferable (proxy) operand of this operation
Transferable
InvalidDnDOperationException | if a drag is not outstanding/extant |
---|
This method returns a boolean
indicating if the given DataFlavor
is
supported by this DropTargetContext
.
df | the DataFlavor
|
---|
DataFlavor
specified is supported
reject the Drag.
called to signal that the drop is unacceptable. must be called during DropTargetListener.drop method invocation.
This method sets the current actions acceptable to
this DropTarget
.
actions | an int representing the supported action(s)
|
---|