(no commit message)
[taxeditor.git] / taxeditor-printpublisher / src / main / java / eu / etaxonomy / printpublisher / internal / PrintpublisherPlugin.java
1 // $Id$
2 /**
3 * Copyright (C) 2007 EDIT
4 * European Distributed Institute of Taxonomy
5 * http://www.e-taxonomy.eu
6 *
7 * The contents of this file are subject to the Mozilla Public License Version 1.1
8 * See LICENSE.TXT at the top of this package for the full license terms.
9 */
10
11 package eu.etaxonomy.printpublisher.internal;
12
13 import org.apache.log4j.Logger;
14 import org.eclipse.ui.plugin.AbstractUIPlugin;
15 import org.osgi.framework.BundleContext;
16
17 /**
18 * @author n.hoffmann
19 * @created Jul 15, 2010
20 * @version 1.0
21 */
22 public class PrintpublisherPlugin extends AbstractUIPlugin {
23 private static final Logger logger = Logger
24 .getLogger(PrintpublisherPlugin.class);
25
26 // The plug-in ID
27 public static final String PLUGIN_ID = "eu.etaxonomy.taxeditor.editor";
28
29 // The shared instance
30 private static PrintpublisherPlugin plugin;
31
32 /**
33 * The constructor
34 */
35 public PrintpublisherPlugin() {
36 }
37
38 /*
39 * (non-Javadoc)
40 * @see org.eclipse.ui.plugin.AbstractUIPlugin#start(org.osgi.framework.BundleContext)
41 */
42 public void start(BundleContext context) throws Exception {
43 super.start(context);
44 plugin = this;
45 logger.trace("Plugin started: " + this.getBundle().getSymbolicName());
46 }
47
48 /*
49 * (non-Javadoc)
50 * @see org.eclipse.ui.plugin.AbstractUIPlugin#stop(org.osgi.framework.BundleContext)
51 */
52 public void stop(BundleContext context) throws Exception {
53 plugin = null;
54 super.stop(context);
55 logger.trace("Plugin stopped");
56 }
57
58 /**
59 * Returns the shared instance
60 *
61 * @return the shared instance
62 */
63 public static PrintpublisherPlugin getDefault() {
64 return plugin;
65 }
66 }