Drag and Drop

There exist two Interface org.favabeans.base.FacetFacets, shown in Figure 4.6, which support Drag and Drop (DND). They simplify the work of developers by shielding them from the complexities of the standard Java DND code (Package java.awt.dndjava.awt.dnd) while still allowing them to expose DND functionality to UI elements that are DND-capable.

Figure 4.6. The Drag and Drop (DND) Interface org.favabeans.base.FacetFacets.

The Interface org.favabeans.base.DnDTargetContainerDnDTargetContainer Interface org.favabeans.base.FacetFacet provides the behavior implemented when an object is displayed in some sort of iconic form, and something is dropped onto it. While custom views may provide more sophisticated DNDbehavior, simple actions, like dropping a document onto a printer icon (to print it), can be handled by this Interface org.favabeans.base.FacetFacet.

The Interface org.favabeans.base.DataTransferDataTransfer Interface org.favabeans.base.FacetFacet of an object provides a way for an object to publish the Interface org.favabeans.base.TypeTypes into which it can convert itself. This functionality is used in two main cases: (a) by the DND subsystem, when the object is the source of a drag operation; and (b) by "clipboard" operations like "cut", "copy" and "paste".