if (tool instanceof ModifyBoundsTool) {
return new ModifyBoundsCommand(editor);
} else if (tool instanceof ModifyVerticesTool) {
return new ModifyVerticesCommand(editor);
} else if (tool instanceof CreateLineTool) {
return new CreateLineCommand(editor);
} else if (tool instanceof CreatePolyLineTool) {
return new CreatePolyLineCommand(editor);
} else if (tool instanceof ModifyRuleTool) {
return new ModifyRuleCommand(editor);
} else if (tool instanceof CreateBezierCurveTool) {