1 package eu
.etaxonomy
.taxeditor
.editor
.internal
;
3 import org
.apache
.log4j
.Logger
;
4 import org
.eclipse
.ui
.plugin
.AbstractUIPlugin
;
5 import org
.osgi
.framework
.BundleContext
;
7 import eu
.etaxonomy
.taxeditor
.editor
.EditorStateManager
;
8 import eu
.etaxonomy
.taxeditor
.store
.CdmStore
;
11 * The activator class controls the plug-in life cycle
16 public class TaxeditorEditorPlugin
extends AbstractUIPlugin
{
18 /** Constant <code>logger</code> */
19 public static final Logger logger
= Logger
.getLogger(TaxeditorEditorPlugin
.class);
22 /** Constant <code>PLUGIN_ID="eu.etaxonomy.taxeditor.editor"</code> */
23 public static final String PLUGIN_ID
= "eu.etaxonomy.taxeditor.editor";
25 // The shared instance
26 private static TaxeditorEditorPlugin plugin
;
31 public TaxeditorEditorPlugin() {
36 * @see org.eclipse.ui.plugin.AbstractUIPlugin#start(org.osgi.framework.BundleContext)
39 public void start(BundleContext context
) throws Exception
{
42 EditorStateManager stateManager
= new EditorStateManager();
43 CdmStore
.getContextManager().addContextListener(stateManager
);
46 logger
.trace("Plugin started: " + this.getBundle().getSymbolicName());
51 * @see org.eclipse.ui.plugin.AbstractUIPlugin#stop(org.osgi.framework.BundleContext)
54 public void stop(BundleContext context
) throws Exception
{
57 logger
.trace("Plugin stopped");
61 * Returns the shared instance
63 * @return the shared instance
65 public static TaxeditorEditorPlugin
getDefault() {