| /** |
| * <copyright> |
| * |
| * Copyright (c) 2009 Metascape, LLC. |
| * All rights reserved. This program and the accompanying materials |
| * are made available under the terms of the Eclipse Public License v1.0 |
| * which accompanies this distribution, and is available at |
| * http://www.eclipse.org/legal/epl-v10.html |
| * |
| * Contributors: |
| * Metascape - Initial API and Implementation |
| * |
| * </copyright> |
| * |
| */ |
| package org.eclipse.amp.axf.ide; |
| |
| import org.eclipse.ui.IStartup; |
| import org.eclipse.ui.plugin.AbstractUIPlugin; |
| import org.osgi.framework.BundleContext; |
| |
| /** |
| * The activator class controls the plug-in life cycle. |
| */ |
| public class AXFWorkbenchPlugin extends AbstractUIPlugin implements IStartup { |
| |
| // The plug-in ID |
| public static final String PLUGIN_ID = "org.eclipse.amp.axf.ide"; |
| |
| // The shared instance |
| private static AXFWorkbenchPlugin plugin; |
| |
| /** |
| * The constructor. |
| */ |
| public AXFWorkbenchPlugin() { |
| } |
| |
| @Override |
| public void stop(BundleContext context) throws Exception { |
| plugin = null; |
| super.stop(context); |
| } |
| |
| /** |
| * Returns the shared instance. |
| * |
| * @return the shared instance |
| */ |
| public static AXFWorkbenchPlugin getDefault() { |
| return plugin; |
| } |
| |
| /** |
| * |
| * @see org.eclipse.ui.IStartup#earlyStartup() |
| */ |
| public void earlyStartup() { |
| plugin = this; |
| } |
| } |