Package org.apache.webbeans.plugins
Class PluginLoader
- java.lang.Object
-
- org.apache.webbeans.plugins.PluginLoader
-
public class PluginLoader extends Object
OpenWebBeans plugins are used to extend 'core' functionality of the injection mechanism with functionality of other frameworks.
Core functionality are all parts which are available in a standard JDK-1.5 SE runtime. Extended functionality are things like JPA, JSF, EJB etc.
The plugin mechanism is based on the ServiceProvider functionality. A jar containing an OWB plugin has to expose itself in the file
META-INF/services/org.apache.webbeans.plugins.OpenWebBeansPlugin
-
-
Constructor Summary
Constructors Constructor Description PluginLoader()
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description OpenWebBeansEjbLCAPlugingetEjbLCAPlugin()Gets ejb lifecycle annotations pluginorg.apache.webbeans.spi.plugins.OpenWebBeansEjbPlugingetEjbPlugin()Gets ejb pluginorg.apache.webbeans.spi.plugins.OpenWebBeansJavaEEPlugingetJavaEEPlugin()OpenWebBeansJmsPlugingetJmsPlugin()Gets the JMS pluginList<org.apache.webbeans.spi.plugins.OpenWebBeansPlugin>getPlugins()voidshutDown()Tell all the plugins to free up all locked resources.voidstartUp()load and startup all registered plugins.static voidthrowsException(Exception e)
-
-
-
Method Detail
-
startUp
public void startUp() throws WebBeansConfigurationExceptionload and startup all registered plugins. This must be called once the WebApplication is started.- Throws:
WebBeansConfigurationException
-
throwsException
public static void throwsException(Exception e) throws WebBeansConfigurationException
- Throws:
WebBeansConfigurationException
-
shutDown
public void shutDown() throws WebBeansConfigurationExceptionTell all the plugins to free up all locked resources. This must be called before the WebApplication gets undeployed or stopped.- Throws:
WebBeansConfigurationException
-
getPlugins
public List<org.apache.webbeans.spi.plugins.OpenWebBeansPlugin> getPlugins()
- Returns:
- an unmodifiable list of all registered {code OpenWebBeansPlugin}s
-
getEjbPlugin
public org.apache.webbeans.spi.plugins.OpenWebBeansEjbPlugin getEjbPlugin()
Gets ejb plugin- Returns:
- ejb plugin
-
getEjbLCAPlugin
public OpenWebBeansEjbLCAPlugin getEjbLCAPlugin()
Gets ejb lifecycle annotations plugin- Returns:
- ejb LCA plugin
-
getJmsPlugin
public OpenWebBeansJmsPlugin getJmsPlugin()
Gets the JMS plugin- Returns:
- jms plugin
-
getJavaEEPlugin
public org.apache.webbeans.spi.plugins.OpenWebBeansJavaEEPlugin getJavaEEPlugin()
-
-