org.apache.webbeans.spi.plugins
Class AbstractOwbPlugin

java.lang.Object
  extended by org.apache.webbeans.spi.plugins.AbstractOwbPlugin
All Implemented Interfaces:
OpenWebBeansPlugin

public abstract class AbstractOwbPlugin
extends Object
implements OpenWebBeansPlugin

Abstract imlpementation of the OpenWebBeansPlugin interface contract.

This abstraction provides the empty implementation for the interface. If any subclass of this class wants to define customize method, it has to override related method definition.


Constructor Summary
protected AbstractOwbPlugin()
           
 
Method Summary
<T> T
getSupportedService(Class<T> serviceClass)
          Gets service instance.
 void isManagedBean(Class<?> clazz)
          Make sure that the given class is ok for simple web bean conditions, otherwise throw a WebBeansConfigurationException
 void shutDown()
          At shutdown, the plugin must release all locked resources.
 void startUp()
          initialise the plugin.
 boolean supportService(Class<?> serviceClass)
          Returns true if plugin provides given service implementation false otherwise.
 boolean supportsJavaEeComponentInjections(Class<?> targetClass)
          Returns true if given class supports injections, false otherwise.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

AbstractOwbPlugin

protected AbstractOwbPlugin()
Method Detail

isManagedBean

public void isManagedBean(Class<?> clazz)
Make sure that the given class is ok for simple web bean conditions, otherwise throw a WebBeansConfigurationException

Specified by:
isManagedBean in interface OpenWebBeansPlugin
Parameters:
clazz - the class to check

supportsJavaEeComponentInjections

public boolean supportsJavaEeComponentInjections(Class<?> targetClass)
Returns true if given class supports injections, false otherwise.

Specified by:
supportsJavaEeComponentInjections in interface OpenWebBeansPlugin
Parameters:
targetClass - any target class
Returns:
true if given class supports injections

shutDown

public void shutDown()
At shutdown, the plugin must release all locked resources. This is called once before the very plugin gets destroyed. This is usually the case when the WebApplication gets stopped.

Specified by:
shutDown in interface OpenWebBeansPlugin

startUp

public void startUp()
initialise the plugin. This is called once after the very plugin has been loaded.

Specified by:
startUp in interface OpenWebBeansPlugin

supportService

public boolean supportService(Class<?> serviceClass)
Returns true if plugin provides given service implementation false otherwise.

Specified by:
supportService in interface OpenWebBeansPlugin
Parameters:
serviceClass - any service class
Returns:
true if plugin provides given service implementation

getSupportedService

public <T> T getSupportedService(Class<T> serviceClass)
Gets service instance.

Specified by:
getSupportedService in interface OpenWebBeansPlugin
Type Parameters:
T - type
Parameters:
serviceClass - service class
Returns:
service


Copyright © 2008-2011 The Apache Software Foundation. All Rights Reserved.