]> gerrit.simantics Code Review - simantics/platform.git/blob - bundles/org.simantics.msvc.runtime.x86_64/org.simantics.msvc.runtime/src/org/simantics/msvc/runtime/Activator.java
b956a448e937b90f0513f35bf641d10e68820643
[simantics/platform.git] / bundles / org.simantics.msvc.runtime.x86_64 / org.simantics.msvc.runtime / src / org / simantics / msvc / runtime / Activator.java
1 package org.simantics.msvc.runtime;
2
3 import org.osgi.framework.BundleActivator;
4 import org.osgi.framework.BundleContext;
5
6 public class Activator implements BundleActivator {
7
8         private static BundleContext context;
9
10         static BundleContext getContext() {
11                 return context;
12         }
13
14         /*
15          * (non-Javadoc)
16          * @see org.osgi.framework.BundleActivator#start(org.osgi.framework.BundleContext)
17          */
18         public void start(BundleContext bundleContext) throws Exception {
19                 Activator.context = bundleContext;
20                 Runtimes.initialize(Runtimes.VC_2010);
21         }
22
23         /*
24          * (non-Javadoc)
25          * @see org.osgi.framework.BundleActivator#stop(org.osgi.framework.BundleContext)
26          */
27         public void stop(BundleContext bundleContext) throws Exception {
28                 Activator.context = null;
29         }
30
31 }