Author: shane.bryzak(a)jboss.com
Date: 2009-07-07 06:11:53 -0400 (Tue, 07 Jul 2009)
New Revision: 3014
Modified:
tck/trunk/impl/src/main/resources/tck-audit.xml
Log:
updated section 3 assertions
Modified: tck/trunk/impl/src/main/resources/tck-audit.xml
===================================================================
--- tck/trunk/impl/src/main/resources/tck-audit.xml 2009-07-07 09:49:45 UTC (rev 3013)
+++ tck/trunk/impl/src/main/resources/tck-audit.xml 2009-07-07 10:11:53 UTC (rev 3014)
@@ -503,21 +503,11 @@
</assertion>
</section>
- <section id="3" title="Bean Implementation">
+ <section id="3" title="Programming model">
</section>
-
- <section id="3.1" title="Restriction upon bean
instantiation">
- <assertion id="a">
- <text>The bean class is a concrete class and is not required to implement any
special interface or extend any special superclass</text>
- </assertion>
-
- <assertion id="b" testable="false">
- <text>If the application calls a producer method directly, instead of letting
the container call it, the returned object is not a contextual instance and the
capabilities listed in Section 2.1, "Functionality provided by the container to the
bean" will not be available to the returned object.</text>
- </assertion>
- </section>
-
- <section id="3.2" title="Managed beans">
+
+ <section id="3.1" title="Managed beans">
<assertion id="f0">
<text>If the bean class of a managed bean is annotated with both the
|@Interceptor| and |@Decorator| stereotypes, the container automatically detects the
problem and treats it as a definition error, as defined in Section 12.4, "Problems
detected automatically by the container".</text>
</assertion>
@@ -528,26 +518,30 @@
</assertion>
<assertion id="fba">
- <text>If a managed bean has a public field, it must have scope |@Dependent|.
If a managed bean with a public field declares any scope other than |@Dependent|, the
container automatically detects the problem and treats it as a definition error, as
defined in Section 12.4, "Problems detected automatically by the
container".</text>
+ <text>If a managed bean with a public field declares any scope other than
|@Dependent|, the container automatically detects the problem and treats it as a
definition error, as defined in Section 12.4, "Problems detected automatically by the
container".</text>
</assertion>
<assertion id="g">
- <text>If the managed bean class is a parameterized type, it must have scope
|@Dependent|. If a managed bean with a parameterized bean class declares any scope other
than |@Dependent|, the container automatically detects the problem and treats it as a
definition error, as defined in Section 12.4, "Problems detected automatically by the
container".</text>
- </assertion>
+ <text>If the managed bean class is a generic type, it must have scope
|@Dependent|. If a managed bean with a parameterized bean class declares any scope other
than |@Dependent|, the container automatically detects the problem and treats it as a
definition error, as defined in Section 12.4, "Problems detected automatically by the
container".</text>
+ </assertion>
</section>
- <section id="3.2.1" title="Which Java classes are managed
beans?">
+ <section id="3.1.1" title="Which Java classes are managed
beans?">
<assertion id="b">
- <text>A top-level Java class is not a managed bean if it is a non-static
inner class</text>
+ <text>A top-level Java class is not a managed bean if it is a non-static
inner class.</text>
</assertion>
+
<assertion id="ba">
- <text>A top-level Java class that is a static inner class can be a managed
bean</text>
+ <text>A top-level Java class that is a static inner class can be a managed
bean.</text>
+ <note>Implied as the inverse of assertion 3.1.1.b</note>
</assertion>
+
<assertion id="ca">
- <text>A top-level Java class is not a managed bean if it is an abstract
class</text>
+ <text>A top-level Java class is not a managed bean if it is an abstract
class, unless it is annotated |(a)Decorator|.</text>
</assertion>
+
<assertion id="cb">
- <text>A top-level Java class is not a managed bean if it is an
interface</text>
+ <text>A top-level Java class is not a managed bean if it is an interface,
unless it is annotated |(a)Decorator|.</text>
</assertion>
<assertion id="f">
@@ -559,21 +553,21 @@
</assertion>
<assertion id="p">
- <text>A top-level Java class is only a managed bean if it has an appropriate
constructor - a constructor with no parameters</text>
+ <text>A top-level Java class is only a managed bean if it has an appropriate
constructor - a constructor with no parameters.</text>
</assertion>
<assertion id="q">
- <text>A top-level Java class is only a managed bean if it has an appropriate
constructor - a constructor annotated |@Initializer|</text>
+ <text>A top-level Java class is only a managed bean if it has an appropriate
constructor - a constructor annotated |(a)Initializer|.</text>
</assertion>
</section>
- <section id="3.2.2" title="Bean types of a managed bean">
+ <section id="3.1.2" title="Bean types of a managed bean">
<assertion id="a">
- <text>The set of bean types for a simple bean contains the bean class, every
superclass and all interfaces it implements directly or indirectly.</text>
+ <text>The set of bean types for a managed bean contains the bean class, every
superclass and all interfaces it implements directly or indirectly.</text>
</assertion>
</section>
- <section id="3.2.3" title="Declaring a managed bean">
+ <section id="3.1.3" title="Declaring a managed bean">
<assertion id="a">
<text>A managed bean with a constructor that takes no parameters does not
require any special annotations</text>
</assertion>
@@ -603,13 +597,13 @@
</assertion>
</section>
- <section id="3.2.4" title="Bean constructors">
+ <section id="3.1.4" title="Bean constructors">
<assertion id="a">
<text>When the container instantiates a managed bean, it calls the bean
constructor. The bean constructor is a constructor of the bean class</text>
</assertion>
</section>
- <section id="3.2.4.1" title="Declaring a bean constructor">
+ <section id="3.1.4.1" title="Declaring a bean constructor">
<assertion id="a">
<text>The bean constructor may be identified by annotating the constructor
|@Initializer|</text>
</assertion>
@@ -632,7 +626,7 @@
</assertion>
</section>
- <section id="3.2.4.2" title="Bean constructor parameters">
+ <section id="3.1.4.2" title="Bean constructor parameters">
<assertion id="b">
<text>A bean constructor may have any number of parameters.</text>
</assertion>
@@ -642,7 +636,7 @@
</assertion>
</section>
- <section id="3.2.5" title="Specializing a managed bean">
+ <section id="3.1.5" title="Specializing a managed bean">
<assertion id="aa">
<text>If a bean class of a managed bean X is annotated @Specializes, then the
bean class of X must directly extend the bean class of another managed bean Y. Then X
directly specializes Y, as defined in Section 4.3,
"Specialization".</text>
</assertion>
@@ -652,13 +646,13 @@
</assertion>
</section>
- <section id="3.2.6" title="Default name for a managed bean">
+ <section id="3.1.6" title="Default name for a managed bean">
<assertion id="a">
<text>The default name for a managed bean is the unqualified class name of
the bean class, after converting the first character to lower case</text>
</assertion>
</section>
- <section id="3.3" title="Session beans">
+ <section id="3.2" title="Session beans">
<assertion id="aa" testable="false">
<text>A session bean is a bean that is implemented by a session bean with an
EJB 3.x client view. The basic lifecycle and semantics of an EJB session bean are defined
by the EJB specification.</text>
<note>This is a reference to the EJB specification</note>
@@ -693,12 +687,12 @@
</assertion>
<assertion id="i">
- <text>If the session bean class is a parameterized type, it must have scope
|@Dependent|. If a session bean with a parameterized bean class declares any scope other
than |@Dependent|, the container automatically detects the problem and treats it as a
+ <text>If the session bean class is a generic type, it must have scope
|@Dependent|. If a session bean with a parameterized bean class declares any scope other
than |@Dependent|, the container automatically detects the problem and treats it as a
definition error, as defined in Section 12.4, "Problems detected automatically by
the container".</text>
</assertion>
</section>
- <section id="3.3.1" title="EJB remove methods of session
beans">
+ <section id="3.2.1" title="EJB remove methods of session
beans">
<assertion id="a">
<text>If a session bean is a stateful session bean, and the scope is
|@Dependent|, the application may call any EJB remove method of an instance of the session
bean.</text>
</assertion>
@@ -720,7 +714,7 @@
</assertion>
</section>
- <section id="3.3.2" title="Bean types of a session bean">
+ <section id="3.2.2" title="Bean types of a session bean">
<assertion id="aa">
<text>The set of bean types for a session bean contains all local interfaces
of the bean and their superinterfaces.</text>
</assertion>
@@ -738,7 +732,7 @@
</assertion>
</section>
- <section id="3.3.3" title="Declaring a session bean">
+ <section id="3.2.3" title="Declaring a session bean">
<assertion id="a">
<text>A session bean does not require any special annotations</text>
</assertion>
@@ -768,42 +762,33 @@
</assertion>
</section>
- <section id="3.3.4" title="Specializing a session bean">
-
+ <section id="3.2.4" title="Specializing a session bean">
<assertion id="aa">
<text>If a bean class of a session bean X is annotated |@Specializes|, then
the bean class of X must directly extend the bean class of another session bean Y. Then X
directly specializes Y, as defined in Section 4.3
"Specialization".</text>
</assertion>
<assertion id="da">
<text>If the bean class of X does not directly extend the bean class of
another session bean, the container automatically detects the problem and treats it as a
definition error, as defined in Section 12.4, "Problems detected automatically by the
container".</text>
- </assertion>
-
- <assertion id="e">
- <text>Session bean X that specializes session bean Y must support all local
interfaces supported by Y</text>
- </assertion>
-
- <assertion id="f">
- <text>Session bean X that specializes session bean Y must support a
bean-class local view if Y supports a bean-class local view</text>
- </assertion>
+ </assertion>
</section>
- <section id="3.3.5" title="Default name for a session bean">
+ <section id="3.2.5" title="Default name for a session bean">
<assertion id="a">
- <text>The default name for a managed bean is the unqualified class name of
the session bean class, after converting the first character to lower case</text>
+ <text>The default name for a managed bean is the unqualified class name of
the session bean class, after converting the first character to lower case.</text>
</assertion>
</section>
- <section id="3.4" title="Producer methods">
- <assertion id="a">
- <text>A producer method must be a method of a managed bean class or session
bean class</text>
+ <section id="3.3" title="Producer methods">
+ <assertion id="aa">
+ <text>A producer method must be a non-abstract method of a managed bean class
or session bean class.</text>
</assertion>
<assertion id="b">
- <text>A producer method may be static</text>
+ <text>A producer method may be static.</text>
</assertion>
<assertion id="c">
- <text>A producer method may be non-static</text>
+ <text>A producer method may be non-static.</text>
</assertion>
<assertion id="d">
@@ -811,15 +796,15 @@
</assertion>
<assertion id="e">
- <text>If a producer method sometimes returns a null value, then the producer
method must have scope |@Dependent|</text>
+ <text>If a producer method sometimes returns a null value, then the producer
method must have scope |(a)Dependent|.</text>
</assertion>
<assertion id="f">
- <text>If a producer method returns a null value at runtime, and the producer
method declares scope other than |@Dependent|, an |IllegalProductException| is thrown by
the container. This restriction allows the container to use a client proxy, as defined in
Section 5.3, "Client proxies".</text>
+ <text>If a producer method returns a null value at runtime, and the producer
method declares scope other than |@Dependent|, an |IllegalProductException| is thrown by
the container. This restriction allows the container to use a client proxy, as defined in
Section 5.5, "Client proxies".</text>
</assertion>
<assertion id="ga">
- <text>If the producer method return type is a parameterized type, it must
specify an actual type parameter or type variable for each type parameter</text>
+ <text>If the producer method return type is a parameterized type, it must
specify an actual type parameter or type variable for each type parameter.</text>
</assertion>
<assertion id="ha">
@@ -827,39 +812,37 @@
</assertion>
<assertion id="ia">
- <text>If the producer method return type is a parameterized type with a type
variable, it must have scope @Dependent. If a producer
-method with a parameterized return type with a type variable declares any scope other
than |@Dependent|, the container automatically detects the problem and treats it as a
definition error, as defined in Section 12.4, "Problems detected automatically by the
container".</text>
+ <text>If the producer method return type is a parameterized type with a type
variable, it must have scope |@Dependent|. If a producer method with a parameterized
return type with a type variable declares any scope other than |@Dependent|, the container
automatically detects the problem and treats it as a definition error, as defined in
Section 12.4, "Problems detected automatically by the container".</text>
</assertion>
<assertion id="ib">
- <text>If a producer method return type is a type variable the container
automatically detects the problem and treats it as a definition
-error, as defined in Section 12.4, "Problems detected automatically by the
container".</text>
+ <text>If a producer method return type is a type variable the container
automatically detects the problem and treats it as a definition error, as defined in
Section 12.4, "Problems detected automatically by the container".</text>
</assertion>
<assertion id="j" testable="false">
- <text>The application may call producer methods directly. However, if the
application calls a producer method directly, no parameters will be passed to the producer
method by the container; the returned object is not bound to any context; and its
lifecycle is not managed by the container</text>
+ <text>The application may call producer methods directly. However, if the
application calls a producer method directly, no parameters will be passed to the producer
method by the container; the returned object is not bound to any context; and its
lifecycle is not managed by the container.</text>
</assertion>
<assertion id="k">
- <text>A bean may declare multiple producer methods</text>
+ <text>A bean may declare multiple producer methods.</text>
</assertion>
</section>
- <section id="3.4.1" title="Bean types of a producer method">
+ <section id="3.3.1" title="Bean types of a producer method">
<assertion id="a">
<text>If the return type of a producer method is an interface, the set of
bean types contains the return type, all interfaces it extends directly or indirectly and
|java.lang.Object|</text>
</assertion>
<assertion id="b">
- <text>If a return type of a producer method is primitive or is a Java array
type, the set of bean types contains exactly two types: the method return type and
|java.lang.Object|</text>
+ <text>If a return type of a producer method is primitive or is a Java array
type, the set of bean types contains exactly two types: the method return type and
|java.lang.Object|.</text>
</assertion>
<assertion id="c">
- <text>If the return type of a producer method is a class, the set of bean
types contains the return type, every superclass and all interfaces it implements directly
or indirectly</text>
+ <text>If the return type of a producer method is a class, the set of bean
types contains the return type, every superclass and all interfaces it implements directly
or indirectly.</text>
</assertion>
</section>
- <section id="3.4.2" title="Declaring a producer method">
+ <section id="3.3.2" title="Declaring a producer method">
<assertion id="a">
<text>A producer method may be declared by annotating a method with the
|(a)javax.enterprise.inject.Produces| annotation</text>
@@ -872,11 +855,7 @@
<assertion id="bb">
<text>A producer method may specify a name</text>
</assertion>
-
- <assertion id="bc">
- <text>A producer method may specify a deployment type</text>
- </assertion>
-
+
<assertion id="bd">
<text>A producer method may specify stereotypes</text>
</assertion>
@@ -900,9 +879,13 @@
<assertion id="fa">
<text>If a non-static method of a session bean class is annotated
|@Produces|, and the method is not a business method of the session bean, the container
automatically detects the problem and treats it as a definition error, as defined in
Section 12.4, "Problems detected automatically by the container".</text>
</assertion>
+
+ <assertion id="g">
+ <text>Interceptors and decorators may not declare producer methods. If an
interceptor or decorator has a method annotated |@Produces|, the container automatically
detects the problem and treats it as a definition error, as defined in Section 12.4,
"Problems detected automatically by the container".</text>
+ </assertion>
</section>
- <section id="3.4.3" title="Producer method parameters">
+ <section id="3.3.3" title="Producer method parameters">
<assertion id="b">
<text>A producer method may have any number of parameters.</text>
</assertion>
@@ -912,8 +895,7 @@
</assertion>
</section>
- <section id="3.4.4" title="Specializing a producer method">
-
+ <section id="3.3.4" title="Specializing a producer method">
<assertion id="aa">
<text>If a producer method X is annotated |@Specializes|, then it must be
non-static and directly override another producer method Y. Then X directly specializes Y,
as defined in Section 4.3 "Specialization".</text>
</assertion>
@@ -927,45 +909,45 @@
</assertion>
</section>
- <section id="3.4.5" title="Disposal methods">
+ <section id="3.3.5" title="Disposer methods">
<assertion id="a">
- <text>A disposal method must be a method of a managed bean class or session
bean class.</text>
+ <text>A disposer method must be a method of a managed bean class or session
bean class.</text>
</assertion>
<assertion id="b">
- <text>A disposal method may be static</text>
+ <text>A disposer method may be static.</text>
</assertion>
<assertion id="c">
- <text>A disposal method may be non-static</text>
+ <text>A disposer method may be non-static.</text>
</assertion>
<assertion id="d">
- <text>If the bean is a session bean, the disposal method must be a business
method of the EJB or a static method of the bean class</text>
+ <text>If the bean is a session bean, the disposer method must be a business
method of the EJB or a static method of the bean class.</text>
</assertion>
<assertion id="e">
- <text>A bean may declare multiple disposal methods</text>
+ <text>A bean may declare multiple disposer methods.</text>
</assertion>
</section>
- <section id="3.4.6" title="Disposed parameter of a disposal
method">
+ <section id="3.3.6" title="Disposed parameter of a disposer
method">
<assertion id="a">
- <text>Each disposal method must have exactly one disposed parameter, of the
same type as the corresponding producer method return type</text>
+ <text>Each disposer method must have exactly one disposed parameter, of the
same type as the corresponding producer method return type.</text>
</assertion>
<assertion id="ba">
- <text>When searching for disposal methods for a producer method, the
container considers the type and bindings of the disposed parameter. If a disposed
parameter resolves to a producer method declared by the same bean class, according to the
typesafe resolution algorithm, the container must call this method when destroying an
instance returned by that producer method</text>
+ <text>When searching for disposer methods for a producer method, the
container considers the type and bindings of the disposed parameter. If a disposed
parameter resolves to a producer method declared by the same bean class, according to the
rules of typesafe resolution defined in Section 5.3 "Typesafe resolution", the
container must call this method when destroying an instance returned by that producer
method.</text>
</assertion>
<assertion id="da">
- <text>A disposal method may resolve to multiple producer methods declared by
the bean class, in which case the container must call it when destroying any instance
returned by any of these producer methods.</text>
+ <text>A disposer method may resolve to multiple producer methods declared by
the bean class, in which case the container must call it when destroying any instance
returned by any of these producer methods.</text>
</assertion>
</section>
- <section id="3.4.7" title="Declaring a disposal method">
+ <section id="3.3.7" title="Declaring a disposer method">
<assertion id="a">
- <text>A disposal method may be declared by annotating a parameter
|(a)javax.enterprise.inject.Disposes|. That parameter is the disposed
parameter</text>
+ <text>A disposer method may be declared by annotating a parameter
|(a)javax.enterprise.inject.Disposes|. That parameter is the disposed
parameter</text>
</assertion>
<assertion id="b0">
@@ -993,43 +975,43 @@
</assertion>
</section>
- <section id="3.4.8" title="Disposal method parameters">
+ <section id="3.3.8" title="Disposer method parameters">
<assertion id="a">
- <text>In addition to the disposed parameter, a disposal method may declare
additional parameters, which may also specify bindings. These additional parameters are
injection points.</text>
+ <text>In addition to the disposed parameter, a disposer method may declare
additional parameters, which may also specify bindings. These additional parameters are
injection points.</text>
</assertion>
</section>
- <section id="3.4.9" title="Disposal method resolution">
+ <section id="3.3.9" title="Disposer method resolution">
<assertion id="aa">
- <text>When searching for disposal methods for a producer method, the
container searches for disposal methods which are declared by the same bean class as the
producer method, and for which the disposed parameter resolves to the producer method,
according to the typesafe resolution algorithm defined in Section 5.1, "Typesafe
resolution algorithm".</text>
+ <text>When searching for disposer methods for a producer method, the
container searches for disposer methods which are declared by the same bean class as the
producer method, and for which the disposed parameter resolves to the producer method,
according to the typesafe resolution algorithm defined in Section 5.3, "Typesafe
resolution".</text>
</assertion>
<assertion id="ba">
- <text>If there are multiple disposal methods for a single producer method,
the container automatically detects the problem and treats it as a definition error, as
defined in Section 12.4, "Problems detected automatically by the
container".</text>
+ <text>If there are multiple disposer methods for a single producer method,
the container automatically detects the problem and treats it as a definition error, as
defined in Section 12.4, "Problems detected automatically by the
container".</text>
</assertion>
<assertion id="ca">
- <text>If the disposed parameter of a disposal method does not resolve to any
producer method declared by the bean class, the container automatically detects the
problem and treats it as a definition error, as defined in Section 12.4, "Problems
detected automatically by the container".</text>
+ <text>If the disposed parameter of a disposer method does not resolve to any
producer method declared by the bean class, the container automatically detects the
problem and treats it as a definition error, as defined in Section 12.4, "Problems
detected automatically by the container".</text>
</assertion>
</section>
- <section id="3.4.10" title="Default name for a producer
method">
+ <section id="3.3.10" title="Default name for a producer
method">
<assertion id="a">
<text>The default name for a producer method is the method name, unless the
method follows the JavaBeans property getter naming convention, in which case the default
name is the JavaBeans property name</text>
</assertion>
</section>
- <section id="3.5" title="Producer fields">
+ <section id="3.4" title="Producer fields">
<assertion id="a">
<text>A producer field must be a field of a managed bean class or session
bean class</text>
</assertion>
<assertion id="b">
- <text>A producer field may be static</text>
+ <text>A producer field may be static.</text>
</assertion>
<assertion id="c">
- <text>A producer field may be nonstatic</text>
+ <text>A producer field may be non-static.</text>
</assertion>
<assertion id="d">
@@ -1037,7 +1019,7 @@
</assertion>
<assertion id="e">
- <text>If a producer method contains a null value at runtime, and the producer
field declares any other scope, an |IllegalProductException| is thrown by the container.
This restriction allows the container to use a client proxy, as defined in Section 5.3,
"Client proxies"</text>
+ <text>If a producer method contains a null value at runtime, and the producer
field declares any other scope, an |IllegalProductException| is thrown by the container.
This restriction allows the container to use a client proxy, as defined in Section 5.5,
"Client proxies"</text>
</assertion>
<assertion id="fa">
@@ -1066,7 +1048,7 @@
</assertion>
</section>
- <section id="3.5.1" title="Bean types of a producer field">
+ <section id="3.4.1" title="Bean types of a producer field">
<assertion id="a">
<text>The bean types of a producer field depend upon the field type. If the
field type is an interface, the set of bean types contains the field type, all interfaces
it extends directly or indirectly and java.lang.Object</text>
</assertion>
@@ -1080,41 +1062,37 @@
</assertion>
</section>
- <section id="3.5.2" title="Declaring a producer field using
annotations">
+ <section id="3.4.2" title="Declaring a producer field">
<assertion id="a">
<text>A producer field may be declared by annotating a field with the
|(a)javax.enterprise.inject.Produces| annotation</text>
</assertion>
<assertion id="b">
- <text>A producer field may specify a scope</text>
+ <text>A producer field may specify a scope.</text>
</assertion>
<assertion id="c">
- <text>A producer field may specify a name</text>
+ <text>A producer field may specify a name.</text>
</assertion>
- <assertion id="d">
- <text>A producer field may specify a deployment type</text>
- </assertion>
-
<assertion id="e">
- <text>A producer field may specify stereotypes</text>
+ <text>A producer field may specify stereotypes.</text>
</assertion>
<assertion id="f">
- <text>A producer field may specify bindings</text>
+ <text>A producer field may specify bindings.</text>
</assertion>
</section>
- <section id="3.5.3" title="Default name for a producer
field">
+ <section id="3.4.3" title="Default name for a producer
field">
<assertion id="a">
<text>The default name for a producer field is the field name</text>
</assertion>
</section>
- <section id="3.6" title="Resources">
- <assertion id="k">
- <text>A resource always has scope |@Dependent|</text>
+ <section id="3.5" title="Resources">
+ <assertion id="ka">
+ <text>The container is not required to support resources with scope other
than |(a)Dependent|.</text>
</assertion>
<assertion id="l">
@@ -1122,7 +1100,7 @@
</assertion>
</section>
- <section id="3.6.1" title="Declaring a resource">
+ <section id="3.5.1" title="Declaring a resource">
<assertion id="aa">
<text>A resource may be declared by specifying a Java EE component
environment injection annotation as part of a producer field declaration.</text>
</assertion>
@@ -1158,201 +1136,35 @@
</section>
- <section id="3.6.2" title="Bean types of a resource">
+ <section id="3.5.2" title="Bean types of a resource">
<assertion id="a">
<text>The bean types of a resource are the declared type of the field
declaration, together with |java.lang.Object|.</text>
</assertion>
</section>
- <section id="3.6.3" title="The JTA TransactionManager">
+ <section id="3.6" title="Additional built-in beans">
<assertion id="a">
- <text>The container must provide a built-in resource with bean type
|javax.transaction.TransactionManager| and binding |@Current|, representing a reference to
the JTA transaction manager.</text>
+ <text>A Java EE or embeddable EJB container must provide a bean with binding
|@Current| and bean type |javax.transaction.UserTransaction|, allowing injection of a
reference to the JTA |UserTransaction|.</text>
</assertion>
- </section>
-
- <section id="3.7" title="Message destinations">
+
<assertion id="b">
- <text>JMS queue resources must allow the direct injection of the
|Queue|</text>
+ <text>A Java EE or embeddable EJB container must provide a bean with binding
|@Current| and bean type |javax.security.Principal|, allowing injection of a |Principal|
representing the current caller identity.</text>
</assertion>
<assertion id="c">
- <text>JMS queue resources must allow the direct injection of the
|QueueConnection|</text>
+ <text>A Java EE or embeddable EJB container must provide a bean with binding
|@Current| and bean type |javax.validation.ValidationFactory|, allowing injection of the
default Bean Validation |ValidationFactory|.</text>
</assertion>
<assertion id="d">
- <text>JMS queue resources must allow the direct injection of the
|QueueSession|</text>
+ <text>A Java EE or embeddable EJB container must provide a bean with binding
|@Current| and bean type |javax.validation.Validator|, allowing injection of a |Validator|
for the default Bean Validation |ValidationFactory|.</text>
</assertion>
<assertion id="e">
- <text>JMS queue resources must allow the direct injection of the
|QueueReceiver|</text>
+ <text>If a Java EE component class has an injection point of type
|UserTransaction| and binding |@Current|, and may not validly make use of the JTA
|UserTransaction| according to the Java EE platform specification, the container
automatically detects the problem and treats it as a definition error, as defined in
Section 12.4, "Problems detected automatically by the container".</text>
</assertion>
-
- <assertion id="f">
- <text>JMS queue resources must allow the direct injection of the
|QueueSender|</text>
- </assertion>
-
- <assertion id="g">
- <text>JMS topic resources must allow the direct injection of the
|Topic|</text>
- </assertion>
-
- <assertion id="h">
- <text>JMS topic resources must allow the direct injection of the
|TopicConnection|</text>
- </assertion>
-
- <assertion id="i">
- <text>JMS topic resources must allow the direct injection of the
|TopicSession|</text>
- </assertion>
-
- <assertion id="j">
- <text>JMS topic resources must allow the direct injection of the
|TopicSubscriber|</text>
- </assertion>
-
- <assertion id="k">
- <text>JMS topic resources must allow the direct injection of the
|TopicPublisher|</text>
- </assertion>
-
- <assertion id="l">
- <text>If the application calls |close()| on an instance of a
|QueueConnection|, an |UnsupportedOperationException| is thrown by the
container.</text>
- </assertion>
-
- <assertion id="m">
- <text>If the application calls |close()| on an instance of a |QueueSession|,
an |UnsupportedOperationException| is thrown by the container.</text>
- </assertion>
-
- <assertion id="n">
- <text>If the application calls |close()| on an instance of a |QueueReceiver|,
an |UnsupportedOperationException| is thrown by the container.</text>
- </assertion>
-
- <assertion id="o">
- <text>If the application calls |close()| on an instance of a |QueueSender|,
an |UnsupportedOperationException| is thrown by the container.</text>
- </assertion>
-
- <assertion id="p">
- <text>If the application calls |close()| on an instance of a
|TopicConnection|, an |UnsupportedOperationException| is thrown by the
container.</text>
- </assertion>
-
- <assertion id="q">
- <text>If the application calls |close()| on an instance of a |TopicSession|,
an |UnsupportedOperationException| is thrown by the container.</text>
- </assertion>
-
- <assertion id="r">
- <text>If the application calls |close()| on an instance of a
|TopicSubscriber|, an |UnsupportedOperationException| is thrown by the
container.</text>
- </assertion>
-
- <assertion id="s">
- <text>If the application calls |close()| on an instance of a
|TopicPublisher|, an |UnsupportedOperationException| is thrown by the
container.</text>
- </assertion>
-
- <assertion id="t">
- <text>A JMS |Queue| resource always has scope |@Dependent|</text>
- </assertion>
-
- <assertion id="u">
- <text>A JMS |QueueConnection| resource always has scope
|@Dependent|</text>
- </assertion>
-
- <assertion id="v">
- <text>A JMS |QueueSession| resource always has scope
|@Dependent|</text>
- </assertion>
-
- <assertion id="w">
- <text>A JMS |QueueReceiver| resource always has scope
|@Dependent|</text>
- </assertion>
-
- <assertion id="x">
- <text>A JMS |QueueSender| resource always has scope
|@Dependent|</text>
- </assertion>
-
- <assertion id="y">
- <text>A JMS |Topic| resource always has scope |@Dependent|</text>
- </assertion>
-
- <assertion id="z">
- <text>A JMS |TopicConnection| resource always has scope
|@Dependent|</text>
- </assertion>
-
- <assertion id="aa">
- <text>A JMS |TopicSession| resource always has scope
|@Dependent|</text>
- </assertion>
-
- <assertion id="ab">
- <text>A JMS |TopicSubscriber| resource always has scope
|@Dependent|</text>
- </assertion>
-
- <assertion id="ac">
- <text>A JMS |TopicPublisher| resource always has scope
|@Dependent|</text>
- </assertion>
-
- <assertion id="ad">
- <text>A JMS |Queue| resource may not declare a bean name</text>
- </assertion>
-
- <assertion id="ae">
- <text>A JMS |QueueConnection| resource may not declare a bean
name</text>
- </assertion>
-
- <assertion id="af">
- <text>A JMS |QueueSession| resource may not declare a bean name</text>
- </assertion>
-
- <assertion id="ag">
- <text>A JMS |QueueReceiver| resource may not declare a bean
name</text>
- </assertion>
-
- <assertion id="ah">
- <text>A JMS |QueueSender| resource may not declare a bean name</text>
- </assertion>
-
- <assertion id="ai">
- <text>A JMS |Topic| resource may not declare a bean name</text>
- </assertion>
-
- <assertion id="aj">
- <text>A JMS |TopicConnection| resource may not declare a bean
name</text>
- </assertion>
-
- <assertion id="ak">
- <text>A JMS |TopicSession| resource may not declare a bean name</text>
- </assertion>
-
- <assertion id="al">
- <text>A JMS |TopicSubscriber| resource may not declare a bean
name</text>
- </assertion>
-
- <assertion id="am">
- <text>A JMS |TopicPublisher| resource may not declare a bean
name</text>
- </assertion>
- </section>
+ </section>
- <section id="3.7.1" title="Bean types of a message
destination">
- <assertion id="a">
- <text>For message destination that represent a queue, the bean types are
|Queue|, |QueueConnection|, |QueueSession| and |QueueSender|</text>
- </assertion>
-
- <assertion id="b">
- <text>For message destination that represent a topic, the bean types are
|Topic|, |TopicConnection|, |TopicSession| and |TopicPublisher|</text>
- </assertion>
-
- <assertion id="c">
- <text>The supertypes |Session|, |MessageProducer|, |MessageConsumer|,
|Connection| and |Destination| are bean types of any message destination.</text>
- </assertion>
- </section>
-
- <section id="3.7.2" title="Declaring a message destination">
- <assertion id="d">
- <text>A message destination may be declared by specifying a |@Resource|
annotation as part of a producer field declaration of type |Topic| or
|Queue|.</text>
- </assertion>
-
- <assertion id="e">
- <text>The |@Resource| annotation specifies the metadata needed to obtain the
topic or queue from the component environment.</text>
- </assertion>
-
- <assertion id="f">
- <text>The bindings and deployment type of the resource are determined by the
producer field declaration.</text>
- </assertion>
- </section>
-
- <section id="3.8" title="Injected fields">
+ <section id="3.7" title="Injected fields">
<assertion id="aa">
<text>An injected field is a non-static~, non-final~ field of a bean
class.</text>
</assertion>
@@ -1378,13 +1190,13 @@
</assertion>
</section>
- <section id="3.8.1" title="Declaring an injected field">
+ <section id="3.7.1" title="Declaring an injected field">
<assertion id="a">
- <text>An injected field may be declared by annotating the field with any
binding type</text>
+ <text>An injected field may be declared by annotating the field with any
binding type.</text>
</assertion>
</section>
- <section id="3.9" title="Initializer methods">
+ <section id="3.8" title="Initializer methods">
<assertion id="aa">
<text>An initializer method is a non-static method of a bean
class.</text>
</assertion>
@@ -1415,11 +1227,15 @@
</assertion>
</section>
- <section id="3.9.1" title="Declaring an initializer method">
+ <section id="3.8.1" title="Declaring an initializer method">
<assertion id="a">
<text>An initializer method may be declared by annotating the method
|(a)javax.enterprise.inject.Initializer|</text>
</assertion>
+ <assertion id="ab">
+ <text>If a generic method of a bean is annotated |@Initializer|, the
container automatically detects the problem and treats it as a definition error, as
defined in Section 12.4, "Problems detected automatically by the
container".</text>
+ </assertion>
+
<assertion id="ba">
<text>If an initializer method is annotated |@Produces|, the container
automatically detects the problem and treats it as a definition error, as defined in
Section 12.4, "Problems detected automatically by the container".</text>
</assertion>
@@ -1434,7 +1250,7 @@
</section>
- <section id="3.9.2" title="Initializer method parameters">
+ <section id="3.8.2" title="Initializer method parameters">
<assertion id="aa">
<text>An initializer method may have any number of parameters.</text>
</assertion>
@@ -1444,13 +1260,13 @@
</assertion>
</section>
- <section id="3.10" title="The default binding at injection
points">
+ <section id="3.9" title="The default binding at injection
points">
<assertion id="a">
<text>If an injection point declares no binding, the default binding
|@Current| is assumed.</text>
</assertion>
</section>
- <section id="3.11" title="Beans with the @New binding">
+ <section id="3.10" title="Beans with the @New binding">
<assertion id="d">
<text>For each managed bean, a second bean exists which has the same bean
class.</text>
</assertion>
@@ -1502,11 +1318,7 @@
<assertion id="p">
<text>This second bean has scope |(a)Dependent|.</text>
</assertion>
-
- <assertion id="q">
- <text>This second bean has deployment type |(a)Standard|.</text>
- </assertion>
-
+
<assertion id="r">
<text>This second bean has exactly one binding:
|(a)javax.enterprise.inject.New(X.class)| where |x| is the bean class.</text>
</assertion>
@@ -1532,12 +1344,16 @@
</assertion>
<assertion id="x">
- <text>This second bean has no disposal methods.</text>
+ <text>This second bean has no disposer methods.</text>
</assertion>
- <assertion id="y">
- <text>This bean is available even if the bean class declares a disabled
deployment type.</text>
+ <assertion id="xb">
+ <text>This second bean is not a policy.</text>
</assertion>
+
+ <assertion id="z">
+ <text>When the binding |@New| is specified at an injection point and no value
member is explicitly specified, the container defaults the value to the declared type of
the injection point.</text>
+ </assertion>
</section>
<section id="4" title="Inheritance and specialization">