/** @see org.eclipse.gef.commands.Command#undo() */ public void undo() { oldSource.removeOutput(newIncomingTransition); oldTarget.removeInput(newOutgoingTransition); newActivity.removeInput(newIncomingTransition); newActivity.removeOutput(newOutgoingTransition); parent.removeChild(newActivity); oldSource.addOutput(transition); oldTarget.addInput(transition); }
/** @see org.eclipse.gef.commands.Command#execute() */ public void execute() { oldSource.removeOutput(transition); oldTarget.removeInput(transition); parent.addChild(newActivity); newIncomingTransition = new Transition(oldSource, newActivity); newOutgoingTransition = new Transition(newActivity, oldTarget); }