@Override public boolean prepare() { style = view.getNamedStyle(styleClass, styleName); if (needsCreate = (style == null)) { style = (NamedStyle) NotationFactory.eINSTANCE.create(styleClass); style.setName(styleName); } command = createCommand(); // return true; return command.canExecute(); }