org.apache.webbeans.config
Class OpenWebBeansConfiguration

java.lang.Object
  extended by org.apache.webbeans.config.OpenWebBeansConfiguration

public class OpenWebBeansConfiguration
extends Object

Defines configuration for OpenWebBeans. The algorithm is easy:


Field Summary
static String APPLICATION_IS_JSP
          Application is core JSP
static String APPLICATION_SUPPORTS_CONVERSATION
          Supports conversations
static String CONTAINER_LIFECYCLE
          Container lifecycle
static String CONTEXTS_SERVICE
          Contexts Service
static String CONVERSATION_PERIODIC_DELAY
          Conversation periodic delay in ms.
static String CONVERSATION_SERVICE
          Conversation Service
static String CONVERSATION_TIMEOUT_INTERVAL
          Timeout interval in ms
static String EAGER_SESSION_INITIALISATION
          By default we do _not_ force session creation in our WebBeansConfigurationListener.
static String EL_ADAPTOR_CLASS
          EL Adaptor
static String GENERATOR_JAVA_VERSIN
          The Java Version to use for the generated proxy classes.
static String IGNORED_INTERFACES
          a comma-separated list of fully qualified class names that should be ignored when determining if a decorator matches its delegate.
static String INTERCEPTOR_FORCE_NO_CHECKED_EXCEPTIONS
          Lifycycle methods like PostConstruct and PreDestroy must not define a checked Exception regarding to the spec.
static String JNDI_SERVICE
          JNDI Service SPI
static String PRODUCER_INTERCEPTION_SUPPORT
           
static String PROXY_MAPPING_PREFIX
          prefix followed by the fully qualified scope name, for configuring InterceptorHandlers for our proxies.
static String RESOURCE_INJECTION_SERVICE
          Resource Injection Service
static String SCANNER_SERVICE
          Scanner Service
static String SECURITY_SERVICE
          Security Service
static String TRANSACTION_SERVICE
          Transaction Service
static String USE_BDA_BEANSXML_SCANNER
          Deprecated. as spec section 5 and 12 contradict each other and the BDA per jar handling is broken anyway
static String USE_EJB_DISCOVERY
          Use EJB Discovery or not
static String VALIDATOR_SERVICE
          Validator Service
 
Constructor Summary
OpenWebBeansConfiguration()
          Parse configuration.
OpenWebBeansConfiguration(Properties properties)
          you can configure this externally as well.
 
Method Summary
 String getGeneratorJavaVersion()
           
 Set<String> getIgnoredInterfaces()
           
 String getProperty(String key)
          Gets property.
 String getProperty(String key, String defaultValue)
          Gets property value.
 boolean isJspApplication()
          Gets jsp property.
 void parseConfiguration()
          (re)read the configuration from the resources in the classpath.
 void setProperty(String key, Object value)
          Sets given property.
 boolean supportsConversation()
          Gets conversation supports property.
 boolean supportsInterceptionOnProducers()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

CONVERSATION_PERIODIC_DELAY

public static final String CONVERSATION_PERIODIC_DELAY
Conversation periodic delay in ms.

See Also:
Constant Field Values

CONVERSATION_TIMEOUT_INTERVAL

public static final String CONVERSATION_TIMEOUT_INTERVAL
Timeout interval in ms

See Also:
Constant Field Values

INTERCEPTOR_FORCE_NO_CHECKED_EXCEPTIONS

public static final String INTERCEPTOR_FORCE_NO_CHECKED_EXCEPTIONS
Lifycycle methods like PostConstruct and PreDestroy must not define a checked Exception regarding to the spec. But this is often unnecessary restrictive so we allow to disable this check application wide.

See Also:
Constant Field Values

USE_EJB_DISCOVERY

public static final String USE_EJB_DISCOVERY
Use EJB Discovery or not

See Also:
Constant Field Values

CONTAINER_LIFECYCLE

public static final String CONTAINER_LIFECYCLE
Container lifecycle

See Also:
Constant Field Values

JNDI_SERVICE

public static final String JNDI_SERVICE
JNDI Service SPI

See Also:
Constant Field Values

SCANNER_SERVICE

public static final String SCANNER_SERVICE
Scanner Service

See Also:
Constant Field Values

CONTEXTS_SERVICE

public static final String CONTEXTS_SERVICE
Contexts Service

See Also:
Constant Field Values

CONVERSATION_SERVICE

public static final String CONVERSATION_SERVICE
Conversation Service

See Also:
Constant Field Values

RESOURCE_INJECTION_SERVICE

public static final String RESOURCE_INJECTION_SERVICE
Resource Injection Service

See Also:
Constant Field Values

SECURITY_SERVICE

public static final String SECURITY_SERVICE
Security Service

See Also:
Constant Field Values

VALIDATOR_SERVICE

public static final String VALIDATOR_SERVICE
Validator Service

See Also:
Constant Field Values

TRANSACTION_SERVICE

public static final String TRANSACTION_SERVICE
Transaction Service

See Also:
Constant Field Values

APPLICATION_IS_JSP

public static final String APPLICATION_IS_JSP
Application is core JSP

See Also:
Constant Field Values

APPLICATION_SUPPORTS_CONVERSATION

public static final String APPLICATION_SUPPORTS_CONVERSATION
Supports conversations

See Also:
Constant Field Values

PRODUCER_INTERCEPTION_SUPPORT

public static final String PRODUCER_INTERCEPTION_SUPPORT
See Also:
Constant Field Values

EL_ADAPTOR_CLASS

public static final String EL_ADAPTOR_CLASS
EL Adaptor

See Also:
Constant Field Values

PROXY_MAPPING_PREFIX

public static final String PROXY_MAPPING_PREFIX
prefix followed by the fully qualified scope name, for configuring InterceptorHandlers for our proxies.

See Also:
Constant Field Values

USE_BDA_BEANSXML_SCANNER

public static final String USE_BDA_BEANSXML_SCANNER
Deprecated. as spec section 5 and 12 contradict each other and the BDA per jar handling is broken anyway
Use BDABeansXmlScanner to determine if interceptors, decorators, and alternatives are enabled in the beans.xml of a given BDA. For an application containing jar1 and jar2, this implies that an interceptor enabled in the beans.xml of jar1 is not automatically enabled in jar2

See Also:
Constant Field Values

IGNORED_INTERFACES

public static final String IGNORED_INTERFACES
a comma-separated list of fully qualified class names that should be ignored when determining if a decorator matches its delegate. These are typically added by weaving or bytecode modification.

See Also:
Constant Field Values

EAGER_SESSION_INITIALISATION

public static final String EAGER_SESSION_INITIALISATION
By default we do _not_ force session creation in our WebBeansConfigurationListener. We only create the Session if we really need the SessionContext. E.g. when we create a Contextual Instance in it. Sometimes this creates a problem as the HttpSession can only be created BEFORE anything got written back to the client. With this configuration you can choose between 3 settings

See Also:
Constant Field Values

GENERATOR_JAVA_VERSIN

public static final String GENERATOR_JAVA_VERSIN
The Java Version to use for the generated proxy classes. If "auto" then we will pick the version of the current JVM. The default is set to "1.6" as some tools in jetty/tomcat/etc still cannot properly handle Java8 (mostly due to older Eclipse JDT versions).

See Also:
Constant Field Values
Constructor Detail

OpenWebBeansConfiguration

public OpenWebBeansConfiguration(Properties properties)
you can configure this externally as well.

Parameters:
properties -

OpenWebBeansConfiguration

public OpenWebBeansConfiguration()
Parse configuration.

Method Detail

parseConfiguration

public void parseConfiguration()
                        throws WebBeansConfigurationException
(re)read the configuration from the resources in the classpath.

Throws:
WebBeansConfigurationException
See Also:
DEFAULT_CONFIG_PROPERTIES_NAME, DEFAULT_CONFIG_PROPERTIES_NAME

getProperty

public String getProperty(String key)
Gets property.

Parameters:
key -
Returns:
String with the property value or null

getProperty

public String getProperty(String key,
                          String defaultValue)
Gets property value.

Parameters:
key -
defaultValue -
Returns:
String with the property value or null

setProperty

public void setProperty(String key,
                        Object value)
Sets given property.

Parameters:
key - property name
value - property value

isJspApplication

public boolean isJspApplication()
Gets jsp property.

Returns:
true if jsp

supportsConversation

public boolean supportsConversation()
Gets conversation supports property.

Returns:
true if supports

getIgnoredInterfaces

public Set<String> getIgnoredInterfaces()

supportsInterceptionOnProducers

public boolean supportsInterceptionOnProducers()

getGeneratorJavaVersion

public String getGeneratorJavaVersion()


Copyright © 2008–2015 The Apache Software Foundation. All rights reserved.