DropTargetExtensionConnector@Deprecated public abstract class VAbstractDropHandler extends Object implements VDropHandler
| Constructor and Description |
|---|
VAbstractDropHandler()
Deprecated.
|
| Modifier and Type | Method and Description |
|---|---|
protected abstract void |
dragAccepted(VDragEvent drag)
Deprecated.
This method is called when a valid drop location was found with
AcceptCriterion either via client or server side check. |
void |
dragEnter(VDragEvent drag)
Deprecated.
The default implementation in
VAbstractDropHandler checks if the
Transferable is accepted. |
void |
dragLeave(VDragEvent drag)
Deprecated.
Default implementation does nothing.
|
void |
dragOver(VDragEvent drag)
Deprecated.
Default implementation does nothing.
|
boolean |
drop(VDragEvent drag)
Deprecated.
The default implemmentation visits server if
AcceptCriterion
can't be verified on client or if AcceptCriterion are met on
client. |
abstract ComponentConnector |
getConnector()
Deprecated.
Returns the Paintable who owns this
VAbstractDropHandler. |
void |
updateAcceptRules(UIDL uidl)
Deprecated.
Implementor/user of
VAbstractDropHandler must pass the UIDL
painted by AcceptCriterion to this method. |
protected void |
validate(VAcceptCallback cb,
VDragEvent event)
Deprecated.
Validates the given drag event when all existing DnD-related tasks are
completed, and triggers the callback if the validation was successful.
|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitgetApplicationConnectionpublic void updateAcceptRules(UIDL uidl)
VAbstractDropHandler must pass the UIDL
painted by AcceptCriterion to this method. Practically the
details about AcceptCriterion are saved.uidl - the accept criterion UIDLpublic void dragOver(VDragEvent drag)
dragOver in interface VDropHandlerdrag - the latest drag eventpublic void dragLeave(VDragEvent drag)
dragLeave in interface VDropHandlerdrag - DragEvent which contains the transferable and other
information for the operationpublic void dragEnter(VDragEvent drag)
VAbstractDropHandler checks if the
Transferable is accepted.
If transferable is accepted (either via server visit or client side
rules) the default implementation calls abstract
dragAccepted(VDragEvent) method.
If drop handler has distinct places where some parts may accept the
Transferable and others don't, one should use similar validation
logic in dragOver method and replace this method with empty
implementation.
dragEnter in interface VDropHandlerdrag - DragEvent which contains the transferable and other
information for the operationprotected abstract void dragAccepted(VDragEvent drag)
AcceptCriterion either via client or server side check.
Implementations can set some hints for users here to highlight that the drag is on a valid drop location.
drag - the drag eventprotected void validate(VAcceptCallback cb, VDragEvent event)
cb - the callback that handles acceptance if the target is validevent - the drag eventpublic boolean drop(VDragEvent drag)
AcceptCriterion
can't be verified on client or if AcceptCriterion are met on
client.drop in interface VDropHandlerdrag - VDragEvent which contains the transferable and other
information for the operationpublic abstract ComponentConnector getConnector()
VAbstractDropHandler. Server
side counterpart of the Paintable is expected to implement
DropTarget interface.getConnector in interface VDropHandlerCopyright © 2021 Vaadin Ltd. All rights reserved.