org.jboss.weld.bootstrap.api
Enum Environments

java.lang.Object
  extended by java.lang.Enum<Environments>
      extended by org.jboss.weld.bootstrap.api.Environments
All Implemented Interfaces:
Serializable, Comparable<Environments>, Environment

public enum Environments
extends Enum<Environments>
implements Environment

Requirements for various well known environments.

Author:
Pete Muir

Enum Constant Summary
EE
          Java EE5 or Java EE6 In this environment, Weld requires that InjectionServices are present, and expects the container to use this callback to perform EE-style injection
EE_INJECT
          Java EE5 or Java EE6 In this environment, Weld requires that JpaInjectionServices, ResourceInjectionServices and EjbInjectionServices are present, and so will perform EE-style field injection on managed beans itself
SE
          Java SE
SERVLET
          Servlet container such as Tomcat
 
Method Summary
 Set<Class<? extends Service>> getRequiredBeanDeploymentArchiveServices()
           
 Set<Class<? extends Service>> getRequiredDeploymentServices()
          The deployment scoped services required for this environment
static Environments valueOf(String name)
          Returns the enum constant of this type with the specified name.
static Environments[] values()
          Returns an array containing the constants of this enum type, in the order they are declared.
 
Methods inherited from class java.lang.Enum
clone, compareTo, equals, finalize, getDeclaringClass, hashCode, name, ordinal, toString, valueOf
 
Methods inherited from class java.lang.Object
getClass, notify, notifyAll, wait, wait, wait
 

Enum Constant Detail

EE_INJECT

public static final Environments EE_INJECT
Java EE5 or Java EE6 In this environment, Weld requires that JpaInjectionServices, ResourceInjectionServices and EjbInjectionServices are present, and so will perform EE-style field injection on managed beans itself


EE

public static final Environments EE
Java EE5 or Java EE6 In this environment, Weld requires that InjectionServices are present, and expects the container to use this callback to perform EE-style injection


SERVLET

public static final Environments SERVLET
Servlet container such as Tomcat


SE

public static final Environments SE
Java SE

Method Detail

values

public static Environments[] values()
Returns an array containing the constants of this enum type, in the order they are declared. This method may be used to iterate over the constants as follows:
for (Environments c : Environments.values())
    System.out.println(c);

Returns:
an array containing the constants of this enum type, in the order they are declared

valueOf

public static Environments valueOf(String name)
Returns the enum constant of this type with the specified name. The string must match exactly an identifier used to declare an enum constant in this type. (Extraneous whitespace characters are not permitted.)

Parameters:
name - the name of the enum constant to be returned.
Returns:
the enum constant with the specified name
Throws:
IllegalArgumentException - if this enum type has no constant with the specified name
NullPointerException - if the argument is null

getRequiredDeploymentServices

public Set<Class<? extends Service>> getRequiredDeploymentServices()
Description copied from interface: Environment
The deployment scoped services required for this environment

Specified by:
getRequiredDeploymentServices in interface Environment
Returns:
the services to require

getRequiredBeanDeploymentArchiveServices

public Set<Class<? extends Service>> getRequiredBeanDeploymentArchiveServices()
Specified by:
getRequiredBeanDeploymentArchiveServices in interface Environment


Copyright © 2013 Seam Framework. All Rights Reserved.