]> gerrit.simantics Code Review - simantics/platform.git/blob - bundles/org.simantics.fileimport.ui/src/org/simantics/fileimport/ui/Activator.java
Merge "Testing SonarQube with Simantics Platform SDK"
[simantics/platform.git] / bundles / org.simantics.fileimport.ui / src / org / simantics / fileimport / ui / Activator.java
1 package org.simantics.fileimport.ui;\r
2 \r
3 import org.eclipse.ui.plugin.AbstractUIPlugin;\r
4 import org.osgi.framework.BundleContext;\r
5 \r
6 /**\r
7  * The activator class controls the plug-in life cycle\r
8  */\r
9 public class Activator extends AbstractUIPlugin {\r
10 \r
11         // The plug-in ID\r
12         public static final String PLUGIN_ID = "org.simantics.fileimport.ui"; //$NON-NLS-1$\r
13 \r
14         // The shared instance\r
15         private static Activator plugin;\r
16         \r
17         /**\r
18          * The constructor\r
19          */\r
20         public Activator() {\r
21         }\r
22 \r
23         /*\r
24          * (non-Javadoc)\r
25          * @see org.eclipse.ui.plugin.AbstractUIPlugin#start(org.osgi.framework.BundleContext)\r
26          */\r
27         public void start(BundleContext context) throws Exception {\r
28                 super.start(context);\r
29                 plugin = this;\r
30         }\r
31 \r
32         /*\r
33          * (non-Javadoc)\r
34          * @see org.eclipse.ui.plugin.AbstractUIPlugin#stop(org.osgi.framework.BundleContext)\r
35          */\r
36         public void stop(BundleContext context) throws Exception {\r
37                 plugin = null;\r
38                 super.stop(context);\r
39         }\r
40 \r
41         /**\r
42          * Returns the shared instance\r
43          *\r
44          * @return the shared instance\r
45          */\r
46         public static Activator getDefault() {\r
47                 return plugin;\r
48         }\r
49 \r
50 }\r