Skip to content

Package: Activator

Activator

nameinstructionbranchcomplexitylinemethod
Activator()
M: 0 C: 3
100%
M: 0 C: 0
100%
M: 0 C: 1
100%
M: 0 C: 1
100%
M: 0 C: 1
100%
start(BundleContext)
M: 0 C: 46
100%
M: 0 C: 0
100%
M: 0 C: 1
100%
M: 0 C: 12
100%
M: 0 C: 1
100%
stop(BundleContext)
M: 0 C: 1
100%
M: 0 C: 0
100%
M: 0 C: 1
100%
M: 0 C: 1
100%
M: 0 C: 1
100%

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: * Neil Mackenzie - initial implementation
13: ******************************************************************************/
14: package org.eclipse.emf.ecp.core.rap;
15:
16: import java.util.Dictionary;
17: import java.util.Hashtable;
18:
19: import org.eclipse.core.runtime.Plugin;
20: import org.eclipse.emf.ecp.core.ECPProjectManager;
21: import org.eclipse.emf.ecp.core.ECPProviderRegistry;
22: import org.eclipse.emf.ecp.core.ECPRepositoryManager;
23: import org.eclipse.emf.ecp.core.util.observer.ECPObserverBus;
24: import org.osgi.framework.BundleContext;
25: import org.osgi.framework.Constants;
26:
27: /**
28: * This is the Activator for the ECP Core RAP plugin.
29: *
30: */
31: public class Activator extends Plugin {
32:
33:         @Override
34:         public final void start(final BundleContext context) throws Exception {
35:                 final Dictionary<String, Object> dictionary = new Hashtable<String, Object>();
36:                 dictionary.put(Constants.SERVICE_RANKING, 1000);
37:                 context.registerService(ECPProjectManager.class,
38:                         new ECPProjectManagerFactory(), dictionary);
39:                 context.registerService(ECPProviderRegistry.class,
40:                         new ECPProviderRegistryFactory(), dictionary);
41:                 context.registerService(ECPRepositoryManager.class,
42:                         new ECPRepositoryManagerFactory(), dictionary);
43:                 context.registerService(ECPObserverBus.class,
44:                         new ECPObserverBusFactory(), dictionary);
45:                 super.start(context);
46:         }
47:
48:         @Override
49:         public void stop(final BundleContext context) throws Exception {
50:
51:         }
52:
53: }