org.jboss.webbeans.bootstrap
Class PropertiesBasedBootstrap
java.lang.Object
org.jboss.webbeans.bootstrap.WebBeansBootstrap
org.jboss.webbeans.bootstrap.PropertiesBasedBootstrap
- Direct Known Subclasses:
- ServletBootstrap
public abstract class PropertiesBasedBootstrap
- extends WebBeansBootstrap
An abstract extension of Bootstrap which uses deployment properties for
configuring the application
- Author:
- Pete Muir
|
Method Summary |
protected static
<T> java.lang.reflect.Constructor<? extends T> |
|
getClassConstructor(DeploymentProperties deploymentProperties,
ResourceLoader resourceLoader,
java.lang.String propertyName,
java.lang.Class<T> expectedType,
java.lang.Class<?>... constructorArguments)
Returns any class constructor from the merged list defined by the
specified property. |
protected abstract DeploymentProperties |
getDeploymentProperties()
Gets the deployment properties |
protected static
|
newInstance(java.lang.reflect.Constructor<T> constructor,
java.lang.Object... parameters)
Creates an instance of the type |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
PropertiesBasedBootstrap
public PropertiesBasedBootstrap()
getClassConstructor
protected static <T> java.lang.reflect.Constructor<? extends T> getClassConstructor(DeploymentProperties deploymentProperties,
ResourceLoader resourceLoader,
java.lang.String propertyName,
java.lang.Class<T> expectedType,
java.lang.Class<?>... constructorArguments)
- Returns any class constructor from the merged list defined by the
specified property.
No guarantee is made about which item in the list will returned.
- Type Parameters:
T - The class type- Parameters:
deploymentProperties - The deployment properties to be usedresourceLoader - The resourceLoader to use for class and resource loadingpropertyName - The name of the property to find in the deployment propertiesexpectedType - The expected type or super type of the classconstructorArguments - The arguments of the constructor to select
- Returns:
newInstance
protected static <T> T newInstance(java.lang.reflect.Constructor<T> constructor,
java.lang.Object... parameters)
- Creates an instance of the type
- Parameters:
constructor - The constructor to useparameters - The parameters to pass to the constructor
- Returns:
- An instance of the type
getDeploymentProperties
protected abstract DeploymentProperties getDeploymentProperties()
- Gets the deployment properties
- Returns:
- The deployment properties
- See Also:
DeploymentProperties
Copyright © 2008-2009. All Rights Reserved.