|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.ObjectCommand
com.pnp.xfeature.commands.RemoveCardinalityCommand
public class RemoveCardinalityCommand
The Command class used to remove a node from a feature model diagram
| Constructor Summary | |
|---|---|
RemoveCardinalityCommand(FeatureDiagramModel diagram,
FeatureNodeModel node)
Creates command that removes a cardinality from node |
|
| Method Summary | |
|---|---|
void |
execute()
calls the removeCardinality() method of the FeatureDiagramModel class that saves the position of the cardinality node and removes it from its parent node and refresh canvas afterwards |
int |
getNodeLastPosition()
returns the last position of the cardinality node in the list of child nodes of its parent |
void |
redo()
calls execute() method |
void |
undo()
calls returnCardinality() method of FeatureDiagramModel class that inserts the cardinality node to its original position in the DOM model and refresh canvas afterwards |
| Methods inherited from class java.lang.Object |
|---|
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public RemoveCardinalityCommand(FeatureDiagramModel diagram,
FeatureNodeModel node)
diagram - feature modelnode - parent node with the cardinality to be removed| 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()public int getNodeLastPosition()
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||