1
|
/**
|
2
|
* Copyright (C) 2007 EDIT
|
3
|
* European Distributed Institute of Taxonomy
|
4
|
* http://www.e-taxonomy.eu
|
5
|
*
|
6
|
* The contents of this file are subject to the Mozilla Public License Version 1.1
|
7
|
* See LICENSE.TXT at the top of this package for the full license terms.
|
8
|
*/
|
9
|
package eu.etaxonomy.taxeditor.bulkeditor.e4.handler;
|
10
|
import org.eclipse.core.commands.ParameterizedCommand;
|
11
|
import org.eclipse.e4.core.di.annotations.Execute;
|
12
|
import org.eclipse.e4.ui.model.application.MApplication;
|
13
|
import org.eclipse.e4.ui.workbench.modeling.EModelService;
|
14
|
import org.eclipse.e4.ui.workbench.modeling.EPartService;
|
15
|
|
16
|
import eu.etaxonomy.taxeditor.bulkeditor.BulkEditorUtil;
|
17
|
import eu.etaxonomy.taxeditor.bulkeditor.IBulkEditorConstants;
|
18
|
import eu.etaxonomy.taxeditor.bulkeditor.input.AbstractBulkEditorInput;
|
19
|
import eu.etaxonomy.taxeditor.bulkeditor.input.BulkEditorInputType;
|
20
|
|
21
|
/**
|
22
|
*
|
23
|
* @author pplitzner
|
24
|
* @since Sep 8, 2017
|
25
|
*
|
26
|
*/
|
27
|
public class OpenBulkEditorHandlerE4 {
|
28
|
|
29
|
@Execute
|
30
|
public void execute(ParameterizedCommand command, EPartService partService, MApplication application, EModelService modelService) {
|
31
|
String inputTypeId = (String) command.getParameterMap().get(IBulkEditorConstants.INPUT_TYPE_PARAMETER_ID);
|
32
|
BulkEditorInputType inputType = BulkEditorInputType.getById(inputTypeId);
|
33
|
AbstractBulkEditorInput input = AbstractBulkEditorInput.NewInstance(inputType);
|
34
|
BulkEditorUtil.openBulkEditor(input, modelService, partService, application);
|
35
|
}
|
36
|
|
37
|
|
38
|
}
|