| /***************************************************************************** |
| * Copyright (c) 2019 CEA LIST, and others. |
| * |
| * All rights reserved. This program and the accompanying materials |
| * are made available under the terms of the Eclipse Public License 2.0 |
| * which accompanies this distribution, and is available at |
| * https://www.eclipse.org/legal/epl-2.0/ |
| * |
| * SPDX-License-Identifier: EPL-2.0 |
| * |
| * Contributors: |
| * Nicolas FAUVERGUE (CEA LIST) nicolas.fauvergue@cea.fr - Initial API and implementation |
| * |
| *****************************************************************************/ |
| package org.eclipse.papyrus.gitlight.compare; |
| |
| import org.eclipse.core.runtime.Plugin; |
| import org.osgi.framework.BundleContext; |
| |
| /** |
| * Activator. |
| */ |
| public class ComparePlugin extends Plugin { |
| |
| /** The plugin ID. */ |
| public static final String PLUGIN_ID = "org.eclipse.papyrus.gitlight.compare"; //$NON-NLS-1$ |
| |
| /** This plug-in's shared instance. */ |
| private static ComparePlugin plugin; |
| |
| /** |
| * Returns the shared instance. |
| * |
| * @return The shared instance. |
| */ |
| public static ComparePlugin getDefault() { |
| return plugin; |
| } |
| |
| /** |
| * {@inheritDoc} |
| * |
| * @see org.eclipse.core.runtime.Plugin#start(org.osgi.framework.BundleContext) |
| */ |
| @Override |
| public void start(final BundleContext context) throws Exception { |
| super.start(context); |
| plugin = this; |
| } |
| |
| /** |
| * {@inheritDoc} |
| * |
| * @see org.eclipse.core.runtime.Plugin#stop(org.osgi.framework.BundleContext) |
| */ |
| @Override |
| public void stop(final BundleContext context) throws Exception { |
| plugin = null; |
| super.stop(context); |
| } |
| } |