X-Git-Url: https://gerrit.simantics.org/r/gitweb?a=blobdiff_plain;f=bundles%2Forg.simantics.logging%2Fsrc%2Forg%2Fsimantics%2Flogging%2Finternal%2FActivator.java;fp=bundles%2Forg.simantics.logging%2Fsrc%2Forg%2Fsimantics%2Flogging%2Finternal%2FActivator.java;h=abedac6ea15e12cd9b9aef9b0632666bf94be643;hb=7d5a5691780ed8373e77641b4a08f18cba0b9fab;hp=0000000000000000000000000000000000000000;hpb=33b349001037197a526a49e5820f0317dc74d934;p=simantics%2Fplatform.git diff --git a/bundles/org.simantics.logging/src/org/simantics/logging/internal/Activator.java b/bundles/org.simantics.logging/src/org/simantics/logging/internal/Activator.java new file mode 100644 index 000000000..abedac6ea --- /dev/null +++ b/bundles/org.simantics.logging/src/org/simantics/logging/internal/Activator.java @@ -0,0 +1,30 @@ +package org.simantics.logging.internal; + +import org.osgi.framework.BundleActivator; +import org.osgi.framework.BundleContext; + +public class Activator implements BundleActivator { + + private static BundleContext context; + + public static BundleContext getContext() { + return context; + } + + /* + * (non-Javadoc) + * @see org.osgi.framework.BundleActivator#start(org.osgi.framework.BundleContext) + */ + public void start(BundleContext bundleContext) throws Exception { + Activator.context = bundleContext; + } + + /* + * (non-Javadoc) + * @see org.osgi.framework.BundleActivator#stop(org.osgi.framework.BundleContext) + */ + public void stop(BundleContext bundleContext) throws Exception { + Activator.context = null; + } + +}