Skip to content

Package: FilterPackagesHandler

FilterPackagesHandler

nameinstructionbranchcomplexitylinemethod
FilterPackagesHandler()
M: 3 C: 0
0%
M: 0 C: 0
100%
M: 1 C: 0
0%
M: 1 C: 0
0%
M: 1 C: 0
0%
execute(ECPProject, Shell)
M: 4 C: 0
0%
M: 0 C: 0
100%
M: 1 C: 0
0%
M: 2 C: 0
0%
M: 1 C: 0
0%

Coverage

1: /*******************************************************************************
2: * Copyright (c) 2011-2013 EclipseSource Muenchen GmbH and others.
3: *
4: * All rights reserved. This program and the accompanying materials
5: * are made available under the terms of the Eclipse Public License 2.0
6: * which accompanies this distribution, and is available at
7: * https://www.eclipse.org/legal/epl-2.0/
8: *
9: * SPDX-License-Identifier: EPL-2.0
10: *
11: * Contributors:
12: * David Soto Setzke - initial API and implementation
13: *
14: *******************************************************************************/
15: package org.eclipse.emf.ecp.ui.e4.handlers;
16:
17: import javax.inject.Named;
18:
19: import org.eclipse.e4.core.di.annotations.Execute;
20: import org.eclipse.e4.core.di.annotations.Optional;
21: import org.eclipse.e4.ui.services.IServiceConstants;
22: import org.eclipse.emf.ecp.core.ECPProject;
23: import org.eclipse.emf.ecp.spi.ui.util.ECPHandlerHelper;
24: import org.eclipse.swt.widgets.Shell;
25:
26: /**
27: * Handler to filter the selection of EPackages.
28: *
29: * @author David
30: *
31: */
32: public class FilterPackagesHandler {
33:
34:         /**
35:          * Opens a dialog for adjusting the packages filter.
36:          *
37:          * @param ecpProject The {@link ECPProject} to which the filter should be applied
38:          * @param shell The {@link Shell} which should be used for the dialogs
39:          */
40:         @Execute
41:         public void execute(@Named(IServiceConstants.ACTIVE_SELECTION) @Optional ECPProject ecpProject, Shell shell) {
42:                 ECPHandlerHelper.filterProjectPackages(ecpProject, shell);
43:         }
44: }