added perspective shortcuts for debug and resource to php perspective
[phpeclipse.git] / net.sourceforge.phpeclipse.launching / src / net / sourceforge / phpdt / internal / launching / PHPLaunchingPlugin.java
1 package net.sourceforge.phpdt.internal.launching;
2
3 import net.sourceforge.phpeclipse.PHPeclipsePlugin;
4
5 import org.eclipse.core.resources.IWorkspace;
6 import org.eclipse.core.runtime.IStatus;
7 import org.eclipse.core.runtime.Status;
8 import org.eclipse.ui.plugin.AbstractUIPlugin;
9 import org.osgi.framework.BundleContext;
10
11 public class PHPLaunchingPlugin extends AbstractUIPlugin {
12         public static final String PLUGIN_ID = "net.sourceforge.phpeclipse.launching"; //$NON-NLS-1$
13
14         protected static PHPLaunchingPlugin plugin;
15
16         public PHPLaunchingPlugin() {
17                 super();
18                 plugin = this;
19         }
20         public static PHPLaunchingPlugin getDefault() {
21                 return plugin;
22         }
23
24         public static IWorkspace getWorkspace() {
25                 return PHPeclipsePlugin.getWorkspace();
26         }
27
28         public static void log(IStatus status) {
29                 getDefault().getLog().log(status);
30         }
31
32         public static void log(Throwable e) {
33                 log(new Status(IStatus.ERROR, PLUGIN_ID, IStatus.ERROR, PHPLaunchingMessages.getString("PHPLaunchingPlugin.internalErrorOccurred"), e)); //$NON-NLS-1$
34         }
35         /**
36          * This method is called upon plug-in activation
37          */
38         public void start(BundleContext context) throws Exception {
39                 super.start(context);
40         }
41
42         /**
43          * This method is called when the plug-in is stopped
44          */
45         public void stop(BundleContext context) throws Exception {
46                 super.stop(context);
47         }
48 }