to.etc.domui.util
Interface IDropHandler


public interface IDropHandler

Nodes that can accept dropped things must have this interface defined via setDropHandler(). The instance of this handler determines what happens with the dropped node, and which nodes are acceptable for dropping.

Author:
Frits Jalvingh Created on Dec 9, 2008

Method Summary
 java.lang.String[] getAcceptableTypes()
          Returns the list of types acceptable for this target.
 void onDropped(DropEvent context)
          This is an event function which gets called as soon as a Draggable is dropped on the dropTarget having this handler.
 

Method Detail

getAcceptableTypes

java.lang.String[] getAcceptableTypes()
Returns the list of types acceptable for this target. Only draggable's that have one of these types will be accepted. This MUST return a string array containing at least one string; if not an exception occurs as soon as this gets used.

Returns:
a non-null minimal length=1 String array containing the types that are acceptable for this drop zone.

onDropped

void onDropped(DropEvent context)
               throws java.lang.Exception
This is an event function which gets called as soon as a Draggable is dropped on the dropTarget having this handler. This event gets called after IDragHandler.onDropped() has been called for the dropped draggable.

Parameters:
context -
Throws:
java.lang.Exception