diff options
author | slewis | 2007-01-15 05:48:19 +0000 |
---|---|---|
committer | slewis | 2007-01-15 05:48:19 +0000 |
commit | 0f7de698b96092f8387c586c1d8f8a9a4bde216c (patch) | |
tree | baee8f0da6f6f5afde7e7bf0525af630d8d6ba29 /examples/bundles/org.eclipse.ecf.example.clients | |
parent | a5bc6e5ff24beb53bc4922445775594ec4a06ce9 (diff) | |
download | org.eclipse.ecf-0f7de698b96092f8387c586c1d8f8a9a4bde216c.tar.gz org.eclipse.ecf-0f7de698b96092f8387c586c1d8f8a9a4bde216c.tar.xz org.eclipse.ecf-0f7de698b96092f8387c586c1d8f8a9a4bde216c.zip |
Added activator class
Diffstat (limited to 'examples/bundles/org.eclipse.ecf.example.clients')
-rw-r--r-- | examples/bundles/org.eclipse.ecf.example.clients/META-INF/MANIFEST.MF | 1 | ||||
-rw-r--r-- | examples/bundles/org.eclipse.ecf.example.clients/src/org/eclipse/ecf/example/clients/Activator.java | 40 |
2 files changed, 41 insertions, 0 deletions
diff --git a/examples/bundles/org.eclipse.ecf.example.clients/META-INF/MANIFEST.MF b/examples/bundles/org.eclipse.ecf.example.clients/META-INF/MANIFEST.MF index fc3fa2873..54b12d62c 100644 --- a/examples/bundles/org.eclipse.ecf.example.clients/META-INF/MANIFEST.MF +++ b/examples/bundles/org.eclipse.ecf.example.clients/META-INF/MANIFEST.MF @@ -17,3 +17,4 @@ Bundle-RequiredExecutionEnvironment: J2SE-1.4, CDC-1.1/Foundation-1.1 Import-Package: org.eclipse.core.runtime, org.osgi.framework;version="1.3.0" +Bundle-Activator: org.eclipse.ecf.example.clients.Activator diff --git a/examples/bundles/org.eclipse.ecf.example.clients/src/org/eclipse/ecf/example/clients/Activator.java b/examples/bundles/org.eclipse.ecf.example.clients/src/org/eclipse/ecf/example/clients/Activator.java new file mode 100644 index 000000000..1ec7abab6 --- /dev/null +++ b/examples/bundles/org.eclipse.ecf.example.clients/src/org/eclipse/ecf/example/clients/Activator.java @@ -0,0 +1,40 @@ +package org.eclipse.ecf.example.clients; + +import org.eclipse.core.runtime.Status; +import org.eclipse.ui.plugin.AbstractUIPlugin; +import org.osgi.framework.BundleContext; + +public class Activator extends AbstractUIPlugin { + + private static Activator instance = null; + + public static final String PLUGIN_ID = "org.eclipse.ecf.example.clients"; + public Activator() { + super(); + instance = this; + } + + public static Activator getDefault() { + return instance; + } + + public void log(int status, String message, Throwable exception) { + getLog().log(new Status(status,PLUGIN_ID,message,exception)); + } + /** + * This method is called upon plug-in activation + */ + public void start(BundleContext context) throws Exception { + super.start(context); + } + + /** + * This method is called when the plug-in is stopped + */ + public void stop(BundleContext context) throws Exception { + super.stop(context); + instance = null; + } + + +} |