|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.ObjectCommand
com.pnp.xfeature.commands.CutCommand
public class CutCommand
The Command class used to remove a node from a feature model diagram
| Constructor Summary | |
|---|---|
CutCommand(FeatureDiagramModel diagram,
FeatureNodeModel node,
Clipboard cb)
Creates command that cuts a node from feature model and saves it to the clipboard |
|
| Method Summary | |
|---|---|
void |
execute()
calls cutSubtree() method of the FeatureDiagramModel that cuts the node (and its whole subtree) element to DOM model and consequently updates the canvas |
void |
redo()
calls execute() method |
void |
undo()
calls uncutSubtree() method of the FeatureDiagramModel that returns the node to the list of nodes of its former parent to the right position and consequently updates the canvas |
| Methods inherited from class java.lang.Object |
|---|
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public CutCommand(FeatureDiagramModel diagram,
FeatureNodeModel node,
Clipboard cb)
diagram - the feature modelnode - the parent node
ToDo: rename node to parent| Method Detail |
|---|
public void execute()
org.eclipse.gef.commands.Command#execute()public void redo()
org.eclipse.gef.commands.Command#redo()public void undo()
org.eclipse.gef.commands.Command#undo()
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||