use of org.apache.cayenne.modeler.undo.CreateProcedureParameterUndoableEdit in project cayenne by apache.
the class CreateProcedureParameterAction method performAction.
/**
* Creates ProcedureParameter depending on context.
*/
@Override
public void performAction(ActionEvent e) {
ProjectController mediator = getProjectController();
if (getProjectController().getCurrentProcedure() != null) {
Procedure procedure = getProjectController().getCurrentProcedure();
ProcedureParameter parameter = new ProcedureParameter();
parameter.setName(NameBuilder.builder(parameter, procedure).name());
createProcedureParameter(procedure, parameter);
application.getUndoManager().addEdit(new CreateProcedureParameterUndoableEdit((DataChannelDescriptor) mediator.getProject().getRootNode(), mediator.getCurrentDataMap(), procedure, parameter));
}
}
Aggregations