]> gerrit.simantics Code Review - simantics/r.git/blobdiff - org.simantics.r.fileimport/src/org/simantics/r/fileimport/Activator.java
refs #6653
[simantics/r.git] / org.simantics.r.fileimport / src / org / simantics / r / fileimport / Activator.java
diff --git a/org.simantics.r.fileimport/src/org/simantics/r/fileimport/Activator.java b/org.simantics.r.fileimport/src/org/simantics/r/fileimport/Activator.java
new file mode 100644 (file)
index 0000000..f3be837
--- /dev/null
@@ -0,0 +1,30 @@
+package org.simantics.r.fileimport;\r
+\r
+import org.osgi.framework.BundleActivator;\r
+import org.osgi.framework.BundleContext;\r
+\r
+public class Activator implements BundleActivator {\r
+\r
+       private static BundleContext context;\r
+\r
+       static BundleContext getContext() {\r
+               return context;\r
+       }\r
+\r
+       /*\r
+        * (non-Javadoc)\r
+        * @see org.osgi.framework.BundleActivator#start(org.osgi.framework.BundleContext)\r
+        */\r
+       public void start(BundleContext bundleContext) throws Exception {\r
+               Activator.context = bundleContext;\r
+       }\r
+\r
+       /*\r
+        * (non-Javadoc)\r
+        * @see org.osgi.framework.BundleActivator#stop(org.osgi.framework.BundleContext)\r
+        */\r
+       public void stop(BundleContext bundleContext) throws Exception {\r
+               Activator.context = null;\r
+       }\r
+\r
+}\r