org.eclipse.emf.ecp.ui.e4.handlers
Class NewModelElementHandler
java.lang.Object
org.eclipse.emf.ecp.ui.e4.handlers.NewModelElementHandler
public class NewModelElementHandler
- extends Object
Handler to create new model elements on the root level of ECPProject
s.
- Author:
- Jonas
NewModelElementHandler
public NewModelElementHandler()
execute
@Execute
public void execute(org.eclipse.swt.widgets.Shell shell,
@Named(value="org.eclipse.ui.selection")@Optional
ECPProject ecpProject)
- Opens a dialog to select a new
EObject
to be created.
- Parameters:
shell
- the Shell to display the dialog.ecpProject
- the selected ECPProject
, parent of the newly created
EObject
canExecute
@CanExecute
public boolean canExecute(@Named(value="org.eclipse.ui.selection")@Optional
ECPProject ecpProject)
- Checks if the current selection is an
ECPProject
.
- Parameters:
ecpProject
- the current selection, if it is an ECPProject
or null otherwise.
- Returns:
- if the current selection is an
ECPProject
Copyright © 2015. All Rights Reserved.