Package org.oddjob.arooa.parsing
Interface DragPoint
- All Superinterfaces:
ArooaConfiguration
- All Known Implementing Classes:
DragConfiguration,DragContext
A point in a configuration that supports drag and drop/cut and paste.
- Author:
- rob
-
Method Summary
Modifier and TypeMethodDescriptionbeginChange(ChangeHow how) Begin a change.copy()Provide a copy of the configuration at from this DragPoint as XML.cut()Copy thisDragPoints configuration and remove it.voiddelete()Remove this DragPoint from it's underlying configuration and remove any components in the configuration from theComponentPoolvoidParse an XML Text configuration and add the resultant component to this DragPoint with the given index.QTag[]List the possible children a Drag Point can have for Add Job functionality.booleanTrue if this DragPoint supports the cut operation.booleanTrue if this DragPoint supports the paste operation.Methods inherited from interface org.oddjob.arooa.ArooaConfiguration
parse
-
Method Details
-
beginChange
Begin a change. Changes must happen in a transaction because when dragging a component within the same session the cut must be done before the paste otherwise duplicate IDs would occur.- Parameters:
how- Should an existing transaction be in progress or not.- Returns:
- A transaction. Never null.
-
supportsCut
boolean supportsCut()True if this DragPoint supports the cut operation.- Returns:
- true/false.
-
supportsPaste
boolean supportsPaste()True if this DragPoint supports the paste operation.- Returns:
- true/false.
-
cut
String cut()Copy thisDragPoints configuration and remove it.This is used by the Web Front end. The Swing UI uses
delete(). -
copy
String copy()Provide a copy of the configuration at from this DragPoint as XML.- Returns:
- Text XML.
-
delete
void delete()Remove this DragPoint from it's underlying configuration and remove any components in the configuration from theComponentPoolThis is used by the swing GUI
ArooaTransferHandlerto perform the CUT operation.This operation must be done within the context of a transaction.
-
paste
Parse an XML Text configuration and add the resultant component to this DragPoint with the given index.This operation must be done within the context of a transaction.
- Parameters:
index- The index. -1 will append.config- The configuration.- Throws:
ArooaParseException- If the configuration could not be parsed.
-
possibleChildren
QTag[] possibleChildren()List the possible children a Drag Point can have for Add Job functionality.supportsPaste()must be true for this to work.- Returns:
- All that child tags that could be added with a paste operation.
-