public class ResourcePasteAction extends AbstractResourceUndoAction
Constructor and Description |
---|
ResourcePasteAction(DesignerProjectContext context,
AbstractNavTreeNode sourceNode,
AbstractResourceNavTreeNode parentNode,
Project toPaste,
java.util.UUID toPasteInto,
java.lang.String moduleId,
java.lang.String objectKey)
Creates a paste undo action.
|
ResourcePasteAction(DesignerProjectContext context,
AbstractResourceNavTreeNode parentNode,
Project toPaste,
java.util.UUID toPasteInto,
java.lang.String moduleId,
java.lang.String objectKey)
Deprecated.
|
Modifier and Type | Method and Description |
---|---|
protected java.lang.String |
actionKey() |
protected int |
actionSize() |
boolean |
execute()
This function executes (redoes) the action
|
boolean |
isGroupSequenceIndependent()
This function should return true if a group of these actions can be undone by ONLY calling undo() on the
first action in the group, and redone by ONLY calling execute() on the last action in the group.
|
protected java.lang.String |
objectKey() |
static Project |
prepForPaste(DesignerProjectContext context,
Project fromClipboard,
java.util.UUID pasteInto,
java.lang.String moduleId)
Preps a Project object that was just deserialized out of the clipboard for pasting underneath a given folder
node.
|
boolean |
undo()
This function will reverse the action
|
extractProjectResources, getDescription, requestLocks, updateAndReleaseLocks
@Deprecated public ResourcePasteAction(DesignerProjectContext context, AbstractResourceNavTreeNode parentNode, Project toPaste, java.util.UUID toPasteInto, java.lang.String moduleId, java.lang.String objectKey)
public ResourcePasteAction(DesignerProjectContext context, AbstractNavTreeNode sourceNode, AbstractResourceNavTreeNode parentNode, Project toPaste, java.util.UUID toPasteInto, java.lang.String moduleId, java.lang.String objectKey)
parentNode
- Used to select the child nodes after the paste. Optional.public static Project prepForPaste(DesignerProjectContext context, Project fromClipboard, java.util.UUID pasteInto, java.lang.String moduleId) throws java.lang.Exception
java.lang.Exception
protected java.lang.String actionKey()
actionKey
in class AbstractResourceUndoAction
protected java.lang.String objectKey()
objectKey
in class AbstractResourceUndoAction
protected int actionSize()
actionSize
in class AbstractResourceUndoAction
public boolean execute()
UndoManager.UndoAction
public boolean undo()
UndoManager.UndoAction
public boolean isGroupSequenceIndependent()
UndoManager.UndoAction