View Javadoc

1   /*
2    WSMO Studio - a Semantic Web Service Editor
3    Copyright (c) 2004-2007, Ontotext Lab. / SIRMA Group
4    
5    This library is free software; you can redistribute it and/or modify it under
6    the terms of the GNU Lesser General Public License as published by the Free
7    Software Foundation; either version 2.1 of the License, or (at your option)
8    any later version.
9    This library is distributed in the hope that it will be useful, but WITHOUT
10   ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
11   FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public License for more
12   details.
13   You should have received a copy of the GNU Lesser General Public License along
14   with this library; if not, write to the Free Software Foundation, Inc.,
15   59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
16   */
17  
18  /***
19   * <p>Title: WSMO Studio</p>
20   * <p>Description: Semantic Web Service Editor</p>
21   * <p>Copyright:  Copyright (c) 2004-2007</p>
22   * <p>Company: Ontotext Lab. / SIRMA </p>
23   */
24  
25  package org.wsmostudio.bpmo;
26  
27  import org.eclipse.ui.plugin.AbstractUIPlugin;
28  import org.osgi.framework.BundleContext;
29  import org.sbpm.bpmo.factory.BpmoFactory;
30  import org.sbpm.bpmo.factory.Factory;
31  
32  /***
33   * The activator class controls the plug-in life cycle
34   */
35  public class Activator extends AbstractUIPlugin {
36  
37  	// The plug-in ID
38  	public static final String PLUGIN_ID = "org.wsmostudio.bpmo.ui";
39  
40  	// The shared instance
41  	private static Activator plugin;
42  	
43  	private static BpmoFactory bpmoFactory;
44  	
45  	/***
46  	 * The constructor
47  	 */
48  	public Activator() {
49  		plugin = this;
50  		bpmoFactory = Factory.createFactory(null);
51  	}
52  
53  	/*
54  	 * (non-Javadoc)
55  	 * @see org.eclipse.ui.plugin.AbstractUIPlugin#start(org.osgi.framework.BundleContext)
56  	 */
57  	public void start(BundleContext context) throws Exception {
58  		super.start(context);
59  	}
60  
61  	/*
62  	 * (non-Javadoc)
63  	 * @see org.eclipse.ui.plugin.AbstractUIPlugin#stop(org.osgi.framework.BundleContext)
64  	 */
65  	public void stop(BundleContext context) throws Exception {
66  		plugin = null;
67  		super.stop(context);
68  	}
69  
70  	/***
71  	 * Returns the shared instance
72  	 *
73  	 * @return the shared instance
74  	 */
75  	public static Activator getDefault() {
76  		return plugin;
77  	}
78  	
79  	public static BpmoFactory getBpmoFactory() {
80  		return bpmoFactory;
81  	}
82  
83  }
84  
85  /*
86   * $Log$
87   * Revision 1.1  2007/03/20 10:05:46  alex_simov
88   * SBP modeller initial version
89   *
90   */