Return-Path: X-Original-To: apmail-geronimo-scm-archive@www.apache.org Delivered-To: apmail-geronimo-scm-archive@www.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id 01AA517498 for ; Mon, 16 Mar 2015 20:08:27 +0000 (UTC) Received: (qmail 71898 invoked by uid 500); 16 Mar 2015 20:08:26 -0000 Delivered-To: apmail-geronimo-scm-archive@geronimo.apache.org Received: (qmail 71848 invoked by uid 500); 16 Mar 2015 20:08:26 -0000 Mailing-List: contact scm-help@geronimo.apache.org; run by ezmlm Precedence: bulk list-help: list-unsubscribe: List-Post: Reply-To: dev@geronimo.apache.org List-Id: Delivered-To: mailing list scm@geronimo.apache.org Received: (qmail 71839 invoked by uid 99); 16 Mar 2015 20:08:26 -0000 Received: from eris.apache.org (HELO hades.apache.org) (140.211.11.105) by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 16 Mar 2015 20:08:26 +0000 Received: from hades.apache.org (localhost [127.0.0.1]) by hades.apache.org (ASF Mail Server at hades.apache.org) with ESMTP id 30D64AC02F5 for ; Mon, 16 Mar 2015 20:08:26 +0000 (UTC) Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Subject: svn commit: r1667118 - in /geronimo/specs/trunk/geronimo-jcdi_1.1_spec: ./ src/main/java/javax/decorator/ src/main/java/javax/enterprise/context/ Date: Mon, 16 Mar 2015 20:08:26 -0000 To: scm@geronimo.apache.org From: struberg@apache.org X-Mailer: svnmailer-1.0.9 Message-Id: <20150316200826.30D64AC02F5@hades.apache.org> Author: struberg Date: Mon Mar 16 20:08:25 2015 New Revision: 1667118 URL: http://svn.apache.org/r1667118 Log: GERONIMO-6458 improve JavaDoc Modified: geronimo/specs/trunk/geronimo-jcdi_1.1_spec/pom.xml geronimo/specs/trunk/geronimo-jcdi_1.1_spec/src/main/java/javax/decorator/Decorator.java geronimo/specs/trunk/geronimo-jcdi_1.1_spec/src/main/java/javax/decorator/Delegate.java geronimo/specs/trunk/geronimo-jcdi_1.1_spec/src/main/java/javax/enterprise/context/BusyConversationException.java geronimo/specs/trunk/geronimo-jcdi_1.1_spec/src/main/java/javax/enterprise/context/ContextException.java geronimo/specs/trunk/geronimo-jcdi_1.1_spec/src/main/java/javax/enterprise/context/ContextNotActiveException.java geronimo/specs/trunk/geronimo-jcdi_1.1_spec/src/main/java/javax/enterprise/context/Dependent.java geronimo/specs/trunk/geronimo-jcdi_1.1_spec/src/main/java/javax/enterprise/context/NormalScope.java geronimo/specs/trunk/geronimo-jcdi_1.1_spec/src/main/java/javax/enterprise/context/RequestScoped.java Modified: geronimo/specs/trunk/geronimo-jcdi_1.1_spec/pom.xml URL: http://svn.apache.org/viewvc/geronimo/specs/trunk/geronimo-jcdi_1.1_spec/pom.xml?rev=1667118&r1=1667117&r2=1667118&view=diff ============================================================================== --- geronimo/specs/trunk/geronimo-jcdi_1.1_spec/pom.xml (original) +++ geronimo/specs/trunk/geronimo-jcdi_1.1_spec/pom.xml Mon Mar 16 20:08:25 2015 @@ -30,7 +30,9 @@ Apache Geronimo JCDI Spec 1.1 1.0-SNAPSHOT - Apache Geronimo implementation of the JSR-299 Context and Dependency Injection for the Java EE Platform + + Apache Geronimo implementation of the JSR-346 Context and Dependency Injection 1.1 & 1.2 Specification + http://geronimo.apache.org/maven/${siteId}/${version} Modified: geronimo/specs/trunk/geronimo-jcdi_1.1_spec/src/main/java/javax/decorator/Decorator.java URL: http://svn.apache.org/viewvc/geronimo/specs/trunk/geronimo-jcdi_1.1_spec/src/main/java/javax/decorator/Decorator.java?rev=1667118&r1=1667117&r2=1667118&view=diff ============================================================================== --- geronimo/specs/trunk/geronimo-jcdi_1.1_spec/src/main/java/javax/decorator/Decorator.java (original) +++ geronimo/specs/trunk/geronimo-jcdi_1.1_spec/src/main/java/javax/decorator/Decorator.java Mon Mar 16 20:08:25 2015 @@ -28,7 +28,12 @@ import javax.enterprise.inject.Stereotyp /** * Defines decorator classes. - * + * Classes annotated with @Decorator will get picked up by the CDI container and + * 'decorate' the implemented CDI ManagedBeans. + * + * A Decorator must implement at least one of the Interfaces of it's decorated type. + * + * * @version $Rev$ $Date$ * */ Modified: geronimo/specs/trunk/geronimo-jcdi_1.1_spec/src/main/java/javax/decorator/Delegate.java URL: http://svn.apache.org/viewvc/geronimo/specs/trunk/geronimo-jcdi_1.1_spec/src/main/java/javax/decorator/Delegate.java?rev=1667118&r1=1667117&r2=1667118&view=diff ============================================================================== --- geronimo/specs/trunk/geronimo-jcdi_1.1_spec/src/main/java/javax/decorator/Delegate.java (original) +++ geronimo/specs/trunk/geronimo-jcdi_1.1_spec/src/main/java/javax/decorator/Delegate.java Mon Mar 16 20:08:25 2015 @@ -27,10 +27,12 @@ import java.lang.annotation.Retention; import java.lang.annotation.Target; /** - * Annotates delegate bean. - * - * @version $Rev$ $Date$ + * Defines a delegation point in a {@see Decorator}. + * There must only be one delegation point in a Decorator. + * + * @see javax.decorator.Decorator * + * @version $Rev$ $Date$ */ @Target({FIELD,PARAMETER}) @Retention(RUNTIME) Modified: geronimo/specs/trunk/geronimo-jcdi_1.1_spec/src/main/java/javax/enterprise/context/BusyConversationException.java URL: http://svn.apache.org/viewvc/geronimo/specs/trunk/geronimo-jcdi_1.1_spec/src/main/java/javax/enterprise/context/BusyConversationException.java?rev=1667118&r1=1667117&r2=1667118&view=diff ============================================================================== --- geronimo/specs/trunk/geronimo-jcdi_1.1_spec/src/main/java/javax/enterprise/context/BusyConversationException.java (original) +++ geronimo/specs/trunk/geronimo-jcdi_1.1_spec/src/main/java/javax/enterprise/context/BusyConversationException.java Mon Mar 16 20:08:25 2015 @@ -25,7 +25,7 @@ import javax.enterprise.context.spi.Crea /** * A long running conversation must only be used by one request at the same time! * - * If a parallel long running conversation gets detected, this very Exception will + * If a parallel access to a long running conversation gets detected, this very Exception will * be thrown for the new request and the 2nd request will get a * fresh Conversation assigned. * Modified: geronimo/specs/trunk/geronimo-jcdi_1.1_spec/src/main/java/javax/enterprise/context/ContextException.java URL: http://svn.apache.org/viewvc/geronimo/specs/trunk/geronimo-jcdi_1.1_spec/src/main/java/javax/enterprise/context/ContextException.java?rev=1667118&r1=1667117&r2=1667118&view=diff ============================================================================== --- geronimo/specs/trunk/geronimo-jcdi_1.1_spec/src/main/java/javax/enterprise/context/ContextException.java (original) +++ geronimo/specs/trunk/geronimo-jcdi_1.1_spec/src/main/java/javax/enterprise/context/ContextException.java Mon Mar 16 20:08:25 2015 @@ -18,6 +18,9 @@ */ package javax.enterprise.context; +/** + * Base class for all CDI problems related to {@link javax.enterprise.context.spi.Context}s. + */ public class ContextException extends RuntimeException { private static final long serialVersionUID = -3599813072560026919L; Modified: geronimo/specs/trunk/geronimo-jcdi_1.1_spec/src/main/java/javax/enterprise/context/ContextNotActiveException.java URL: http://svn.apache.org/viewvc/geronimo/specs/trunk/geronimo-jcdi_1.1_spec/src/main/java/javax/enterprise/context/ContextNotActiveException.java?rev=1667118&r1=1667117&r2=1667118&view=diff ============================================================================== --- geronimo/specs/trunk/geronimo-jcdi_1.1_spec/src/main/java/javax/enterprise/context/ContextNotActiveException.java (original) +++ geronimo/specs/trunk/geronimo-jcdi_1.1_spec/src/main/java/javax/enterprise/context/ContextNotActiveException.java Mon Mar 16 20:08:25 2015 @@ -23,9 +23,16 @@ import javax.enterprise.context.spi.Cont import javax.enterprise.context.spi.CreationalContext; /** - * It is used by the Context interface. - * - * + * This Exception is thrown if + * {@link Context#get(javax.enterprise.context.spi.Contextual)} or + * {@link Context#get(javax.enterprise.context.spi.Contextual, javax.enterprise.context.spi.CreationalContext)} + * is called on a Context which is not 'active' in respect to the current thread. + * This ultimately also happens if a CDI scoped Contextual Reference (the CDI proxy for a Contextual Instance) + * of a CDI bean gets accessed in situations where it's Context is not available. + * + * An example of such a case would be calling a method on a @SessionScoped CDI bean in a situation where + * we do not have an active session like e.g. during an @Asynchronous EJB method. + * * @see Context#get(Contextual, CreationalContext) * @see Context#get(Contextual) */ Modified: geronimo/specs/trunk/geronimo-jcdi_1.1_spec/src/main/java/javax/enterprise/context/Dependent.java URL: http://svn.apache.org/viewvc/geronimo/specs/trunk/geronimo-jcdi_1.1_spec/src/main/java/javax/enterprise/context/Dependent.java?rev=1667118&r1=1667117&r2=1667118&view=diff ============================================================================== --- geronimo/specs/trunk/geronimo-jcdi_1.1_spec/src/main/java/javax/enterprise/context/Dependent.java (original) +++ geronimo/specs/trunk/geronimo-jcdi_1.1_spec/src/main/java/javax/enterprise/context/Dependent.java Mon Mar 16 20:08:25 2015 @@ -28,20 +28,24 @@ import java.lang.annotation.Target; import javax.inject.Scope; /** - * Dependent scope type. + *

An @#064;Dependent scoped Contextual instance shares it's lifecycle with + * the Contextual Instance it got injected to. + * @Dependent scoped Contextual Instances also do not get + * a normalscoping-proxy (Contextual Reference). They only get a proxy + * if they are either intercepted or decorated.

+ * + *

As of CDI-1.0 this is the default scope for any class if no other + * scope is explicitly annotated. Since CDI-1.1 this is only the case if the + * beans.xml has a {@code bean-discovery-mode="all"}

+ * *

- * If webbeans or its stereotypes do not define its scope type, - * default scope type is Dependent scope. - *

- * - *

- * Every webbeans instance has an associated dependent context. Each dependent context + * Every CDI instance has an associated dependent context. Each dependent context * is destroyed with its parent webbeans component instance. *

* *

* Please see 8.3 Dependent pseudo-scope of the specification - * for getting furhter information. + * for further information. *

* */ Modified: geronimo/specs/trunk/geronimo-jcdi_1.1_spec/src/main/java/javax/enterprise/context/NormalScope.java URL: http://svn.apache.org/viewvc/geronimo/specs/trunk/geronimo-jcdi_1.1_spec/src/main/java/javax/enterprise/context/NormalScope.java?rev=1667118&r1=1667117&r2=1667118&view=diff ============================================================================== --- geronimo/specs/trunk/geronimo-jcdi_1.1_spec/src/main/java/javax/enterprise/context/NormalScope.java (original) +++ geronimo/specs/trunk/geronimo-jcdi_1.1_spec/src/main/java/javax/enterprise/context/NormalScope.java Mon Mar 16 20:08:25 2015 @@ -26,8 +26,14 @@ import java.lang.annotation.Retention; import java.lang.annotation.Target; /** - * Defines normal scoped meta-data. - * + *

Defines CDI scopes which have a well-defined lifecycle. Examples for such scopes + * are {@link javax.enterprise.context.RequestScoped}, {@link javax.enterprise.context.SessionScoped} + * and {@link javax.enterprise.context.ApplicationScoped}.

+ *

Beans of such a scope will get a normalscoping proxy (Contextual Reference) + * for every injection.

+ * + *

If a NormalScope is {@code passivating} then all it's Contextual Instances need + * to implement {@code java.io.Serializable}.

* @version $Rev$ $Date$ * */ Modified: geronimo/specs/trunk/geronimo-jcdi_1.1_spec/src/main/java/javax/enterprise/context/RequestScoped.java URL: http://svn.apache.org/viewvc/geronimo/specs/trunk/geronimo-jcdi_1.1_spec/src/main/java/javax/enterprise/context/RequestScoped.java?rev=1667118&r1=1667117&r2=1667118&view=diff ============================================================================== --- geronimo/specs/trunk/geronimo-jcdi_1.1_spec/src/main/java/javax/enterprise/context/RequestScoped.java (original) +++ geronimo/specs/trunk/geronimo-jcdi_1.1_spec/src/main/java/javax/enterprise/context/RequestScoped.java Mon Mar 16 20:08:25 2015 @@ -33,7 +33,7 @@ import java.lang.annotation.Target; * *

* Please see Request context lifecycle of the specification - * for getting furher information. + * for further information. *

* * @version $Rev$ $Date$