Weld SVN: r4391 - api/trunk/cdi/src/main/java/javax/enterprise/inject/spi.
by weld-commits@lists.jboss.org
Author: gavin.king(a)jboss.com
Date: 2009-10-29 01:57:43 -0400 (Thu, 29 Oct 2009)
New Revision: 4391
Modified:
api/trunk/cdi/src/main/java/javax/enterprise/inject/spi/InterceptionType.java
Log:
minor
Modified: api/trunk/cdi/src/main/java/javax/enterprise/inject/spi/InterceptionType.java
===================================================================
--- api/trunk/cdi/src/main/java/javax/enterprise/inject/spi/InterceptionType.java 2009-10-29 05:52:34 UTC (rev 4390)
+++ api/trunk/cdi/src/main/java/javax/enterprise/inject/spi/InterceptionType.java 2009-10-29 05:57:43 UTC (rev 4391)
@@ -19,6 +19,7 @@
/**
* Identifies the kind of lifecycle callback or business method
+ * interceptor.
*
* @author Pete Muir
*
15 years, 1 month
Weld SVN: r4390 - api/trunk/cdi/src/main/java/javax/enterprise/inject/spi.
by weld-commits@lists.jboss.org
Author: gavin.king(a)jboss.com
Date: 2009-10-29 01:52:34 -0400 (Thu, 29 Oct 2009)
New Revision: 4390
Added:
api/trunk/cdi/src/main/java/javax/enterprise/inject/spi/ProcessProducer.java
Log:
i should stop smoking crack
Added: api/trunk/cdi/src/main/java/javax/enterprise/inject/spi/ProcessProducer.java
===================================================================
--- api/trunk/cdi/src/main/java/javax/enterprise/inject/spi/ProcessProducer.java (rev 0)
+++ api/trunk/cdi/src/main/java/javax/enterprise/inject/spi/ProcessProducer.java 2009-10-29 05:52:34 UTC (rev 4390)
@@ -0,0 +1,93 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2008, Red Hat Middleware LLC, and individual contributors
+ * by the @authors tag. See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ * http://www.apache.org/licenses/LICENSE-2.0
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+package javax.enterprise.inject.spi;
+
+/**
+ * <p>
+ * The container will fire an event of this type for each
+ * {@linkplain javax.enterprise.inject.Produces producer method or field},
+ * including resources.
+ * </p>
+ * <p>
+ * Any observer of this event is permitted to wrap and/or replace the {@code
+ * Producer}. The container must use the final value of this property, after all
+ * observers have been called, whenever it calls the producer or disposer.
+ * </p>
+ * <p>
+ * For example, this observer decorates the {@code Producer} for the all producer
+ * methods and field of type {@code EntityManager}.
+ * </p>
+ *
+ * <pre>
+ * void decorateEntityManager(@Observes ProcessProducer<?, EntityManager> pp)
+ * {
+ * pit.setProducer(decorate(pp.getProducer()));
+ * }
+ * </pre>
+ * <p>
+ * If any observer method of a {@code ProcessProducer} event throws an exception, the
+ * exception is treated as a definition error by the container.
+ * </p>
+ *
+ * @author David Allen
+ * @param <T> The bean class of the bean that declares the producer method or
+ * field
+ * @param <X> The return type of the producer method or the type of the producer
+ * field
+ */
+public interface ProcessProducer<T, X>
+{
+ /**
+ * Returns the {@link javax.enterprise.inject.spi.AnnotatedField}
+ * representing the producer field or the
+ * {@link javax.enterprise.inject.spi.AnnotatedMethod} representing the
+ * producer method.
+ *
+ * @return the {@link javax.enterprise.inject.spi.AnnotatedMember}
+ * representing the producer
+ */
+ public AnnotatedMember<T> getAnnotatedMember();
+
+ /**
+ * Returns the {@link javax.enterprise.inject.spi.Producer} object that will
+ * be used by the container to call the producer method or read the producer
+ * field.
+ *
+ * @return the {@link javax.enterprise.inject.spi.Producer} invoker object
+ * used by the container
+ */
+ public Producer<X> getProducer();
+
+ /**
+ * Replaces the {@link javax.enterprise.inject.spi.Producer} object that will
+ * be used by the container to call the producer method or read the producer
+ * field.
+ *
+ * @param producer the new {@link javax.enterprise.inject.spi.Producer}
+ * object to use
+ */
+ public void setProducer(Producer<X> producer);
+
+ /**
+ * Registers a definition error with the container, causing the container to
+ * abort deployment after bean discovery is complete.
+ *
+ * @param t The definition error to register as a {@link java.lang.Throwable}
+ */
+ public void addDefinitionError(Throwable t);
+}
15 years, 1 month
Weld SVN: r4389 - api/trunk/cdi/src/main/java/javax/enterprise/inject/spi.
by weld-commits@lists.jboss.org
Author: gavin.king(a)jboss.com
Date: 2009-10-29 01:50:39 -0400 (Thu, 29 Oct 2009)
New Revision: 4389
Removed:
api/trunk/cdi/src/main/java/javax/enterprise/inject/spi/ProcessProducer.java
Log:
remove event that no longer exists in spec!
Deleted: api/trunk/cdi/src/main/java/javax/enterprise/inject/spi/ProcessProducer.java
===================================================================
--- api/trunk/cdi/src/main/java/javax/enterprise/inject/spi/ProcessProducer.java 2009-10-29 05:46:47 UTC (rev 4388)
+++ api/trunk/cdi/src/main/java/javax/enterprise/inject/spi/ProcessProducer.java 2009-10-29 05:50:39 UTC (rev 4389)
@@ -1,93 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source
- * Copyright 2008, Red Hat Middleware LLC, and individual contributors
- * by the @authors tag. See the copyright.txt in the distribution for a
- * full listing of individual contributors.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- * http://www.apache.org/licenses/LICENSE-2.0
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package javax.enterprise.inject.spi;
-
-/**
- * <p>
- * The container will fire an event of this type for each
- * {@linkplain javax.enterprise.inject.Produces producer method or field},
- * including resources.
- * </p>
- * <p>
- * Any observer of this event is permitted to wrap and/or replace the {@code
- * Producer}. The container must use the final value of this property, after all
- * observers have been called, whenever it calls the producer or disposer.
- * </p>
- * <p>
- * For example, this observer decorates the {@code Producer} for the all producer
- * methods and field of type {@code EntityManager}.
- * </p>
- *
- * <pre>
- * void decorateEntityManager(@Observes ProcessProducer<?, EntityManager> pp)
- * {
- * pit.setProducer(decorate(pp.getProducer()));
- * }
- * </pre>
- * <p>
- * If any observer method of a {@code ProcessProducer} event throws an exception, the
- * exception is treated as a definition error by the container.
- * </p>
- *
- * @author David Allen
- * @param <T> The bean class of the bean that declares the producer method or
- * field
- * @param <X> The return type of the producer method or the type of the producer
- * field
- */
-public interface ProcessProducer<T, X>
-{
- /**
- * Returns the {@link javax.enterprise.inject.spi.AnnotatedField}
- * representing the producer field or the
- * {@link javax.enterprise.inject.spi.AnnotatedMethod} representing the
- * producer method.
- *
- * @return the {@link javax.enterprise.inject.spi.AnnotatedMember}
- * representing the producer
- */
- public AnnotatedMember<T> getAnnotatedMember();
-
- /**
- * Returns the {@link javax.enterprise.inject.spi.Producer} object that will
- * be used by the container to call the producer method or read the producer
- * field.
- *
- * @return the {@link javax.enterprise.inject.spi.Producer} invoker object
- * used by the container
- */
- public Producer<X> getProducer();
-
- /**
- * Replaces the {@link javax.enterprise.inject.spi.Producer} object that will
- * be used by the container to call the producer method or read the producer
- * field.
- *
- * @param producer the new {@link javax.enterprise.inject.spi.Producer}
- * object to use
- */
- public void setProducer(Producer<X> producer);
-
- /**
- * Registers a definition error with the container, causing the container to
- * abort deployment after bean discovery is complete.
- *
- * @param t The definition error to register as a {@link java.lang.Throwable}
- */
- public void addDefinitionError(Throwable t);
-}
15 years, 1 month
Weld SVN: r4388 - api/trunk/cdi/src/main/java/javax/enterprise/inject/spi.
by weld-commits@lists.jboss.org
Author: gavin.king(a)jboss.com
Date: 2009-10-29 01:46:47 -0400 (Thu, 29 Oct 2009)
New Revision: 4388
Modified:
api/trunk/cdi/src/main/java/javax/enterprise/inject/spi/InjectionTarget.java
api/trunk/cdi/src/main/java/javax/enterprise/inject/spi/Producer.java
Log:
minor
Modified: api/trunk/cdi/src/main/java/javax/enterprise/inject/spi/InjectionTarget.java
===================================================================
--- api/trunk/cdi/src/main/java/javax/enterprise/inject/spi/InjectionTarget.java 2009-10-29 05:45:41 UTC (rev 4387)
+++ api/trunk/cdi/src/main/java/javax/enterprise/inject/spi/InjectionTarget.java 2009-10-29 05:46:47 UTC (rev 4388)
@@ -20,7 +20,7 @@
/**
* <p>
- * This interface provides operations for performing dependency injection and
+ * Provides operations for performing dependency injection and
* lifecycle callbacks on an instance of a type.
* </p>
*
Modified: api/trunk/cdi/src/main/java/javax/enterprise/inject/spi/Producer.java
===================================================================
--- api/trunk/cdi/src/main/java/javax/enterprise/inject/spi/Producer.java 2009-10-29 05:45:41 UTC (rev 4387)
+++ api/trunk/cdi/src/main/java/javax/enterprise/inject/spi/Producer.java 2009-10-29 05:46:47 UTC (rev 4388)
@@ -22,8 +22,7 @@
/**
* <p>
- * The interface {@link javax.enterprise.inject.spi.Producer} provides a generic
- * operation for producing an instance of a type.
+ * Provides a generic operation for producing an instance of a type.
* </p>
*
* @author Pete Muir
15 years, 1 month
Weld SVN: r4387 - api/trunk/cdi/src/main/java/javax/enterprise/inject/spi.
by weld-commits@lists.jboss.org
Author: gavin.king(a)jboss.com
Date: 2009-10-29 01:45:41 -0400 (Thu, 29 Oct 2009)
New Revision: 4387
Modified:
api/trunk/cdi/src/main/java/javax/enterprise/inject/spi/PassivationCapable.java
Log:
ups
Modified: api/trunk/cdi/src/main/java/javax/enterprise/inject/spi/PassivationCapable.java
===================================================================
--- api/trunk/cdi/src/main/java/javax/enterprise/inject/spi/PassivationCapable.java 2009-10-29 05:45:13 UTC (rev 4386)
+++ api/trunk/cdi/src/main/java/javax/enterprise/inject/spi/PassivationCapable.java 2009-10-29 05:45:41 UTC (rev 4387)
@@ -19,7 +19,7 @@
/**
* Indicates that a custom implementation of
- * {@link javax.enterprise.inject.spi.Bean or
+ * {@link javax.enterprise.inject.spi.Bean} or
* {@link javax.enterprise.context.spi.Contextual}
* is passivation capable.
*
15 years, 1 month
Weld SVN: r4386 - api/trunk/cdi/src/main/java/javax/enterprise/inject/spi.
by weld-commits@lists.jboss.org
Author: gavin.king(a)jboss.com
Date: 2009-10-29 01:45:13 -0400 (Thu, 29 Oct 2009)
New Revision: 4386
Modified:
api/trunk/cdi/src/main/java/javax/enterprise/inject/spi/PassivationCapable.java
Log:
refresh
Modified: api/trunk/cdi/src/main/java/javax/enterprise/inject/spi/PassivationCapable.java
===================================================================
--- api/trunk/cdi/src/main/java/javax/enterprise/inject/spi/PassivationCapable.java 2009-10-29 05:40:18 UTC (rev 4385)
+++ api/trunk/cdi/src/main/java/javax/enterprise/inject/spi/PassivationCapable.java 2009-10-29 05:45:13 UTC (rev 4386)
@@ -18,7 +18,10 @@
package javax.enterprise.inject.spi;
/**
- * Used to indicate that a custom bean is passivation capable.
+ * Indicates that a custom implementation of
+ * {@link javax.enterprise.inject.spi.Bean or
+ * {@link javax.enterprise.context.spi.Contextual}
+ * is passivation capable.
*
* @author Gavin King
* @author David Allen
@@ -27,11 +30,15 @@
public interface PassivationCapable
{
/**
- * A string that uniquely identifies the Bean or Contextual. It is
- * recommended that the string contain the package name of the class that
- * implements Bean or Contextual.
+ * A string that uniquely identifies the instance of
+ * {@link javax.enterprise.inject.spi.Bean} or
+ * {@link javax.enterprise.context.spi.Contextual}. It is
+ * recommended that the string contain the package name of
+ * the class that implements {@code Bean} or {@code Contextual}.
*
- * @return a unique identifier for the Bean or Contextual
+ * @return a unique identifier for the
+ * {@link javax.enterprise.inject.spi.Bean} or
+ * {@link javax.enterprise.context.spi.Contextual}
*/
public String getId();
}
15 years, 1 month
Weld SVN: r4385 - api/trunk/cdi/src/main/java/javax/enterprise/inject/spi.
by weld-commits@lists.jboss.org
Author: gavin.king(a)jboss.com
Date: 2009-10-29 01:40:18 -0400 (Thu, 29 Oct 2009)
New Revision: 4385
Modified:
api/trunk/cdi/src/main/java/javax/enterprise/inject/spi/BeforeShutdown.java
Log:
minor
Modified: api/trunk/cdi/src/main/java/javax/enterprise/inject/spi/BeforeShutdown.java
===================================================================
--- api/trunk/cdi/src/main/java/javax/enterprise/inject/spi/BeforeShutdown.java 2009-10-29 05:35:10 UTC (rev 4384)
+++ api/trunk/cdi/src/main/java/javax/enterprise/inject/spi/BeforeShutdown.java 2009-10-29 05:40:18 UTC (rev 4385)
@@ -18,7 +18,7 @@
/**
* <p>
- * The type of final event the container fires after it has finished processing
+ * The type of the final event the container fires after it has finished processing
* requests and destroyed all contexts. If any observer method of the
* {@code BeforeShutdown} event throws an exception, the exception is ignored by the
* container.
15 years, 1 month
Weld SVN: r4384 - api/trunk/cdi/src/main/java/javax/enterprise/inject/spi.
by weld-commits@lists.jboss.org
Author: gavin.king(a)jboss.com
Date: 2009-10-29 01:35:10 -0400 (Thu, 29 Oct 2009)
New Revision: 4384
Modified:
api/trunk/cdi/src/main/java/javax/enterprise/inject/spi/InjectionTarget.java
api/trunk/cdi/src/main/java/javax/enterprise/inject/spi/Producer.java
Log:
minor improvs
Modified: api/trunk/cdi/src/main/java/javax/enterprise/inject/spi/InjectionTarget.java
===================================================================
--- api/trunk/cdi/src/main/java/javax/enterprise/inject/spi/InjectionTarget.java 2009-10-29 05:23:29 UTC (rev 4383)
+++ api/trunk/cdi/src/main/java/javax/enterprise/inject/spi/InjectionTarget.java 2009-10-29 05:35:10 UTC (rev 4384)
@@ -33,13 +33,12 @@
/**
* <p>
- * Performs dependency injection upon the given object. First, the container
- * performs Java EE component environment injection according to the
- * semantics required by the Java EE platform specification. Next, it sets
- * the value of all injected fields, and then calls all initializer methods.
+ * Performs dependency injection upon the given object. Performs Java EE
+ * component environment injection, sets the value of all injected fields,
+ * and calls all initializer methods.
* </p>
*
- * @param instance The instance upon which to perform injections
+ * @param instance The instance upon which to perform injection
* @param ctx The {@link javax.enterprise.context.spi.CreationalContext} to
* use for creating new instances
*/
Modified: api/trunk/cdi/src/main/java/javax/enterprise/inject/spi/Producer.java
===================================================================
--- api/trunk/cdi/src/main/java/javax/enterprise/inject/spi/Producer.java 2009-10-29 05:23:29 UTC (rev 4383)
+++ api/trunk/cdi/src/main/java/javax/enterprise/inject/spi/Producer.java 2009-10-29 05:35:10 UTC (rev 4384)
@@ -39,9 +39,9 @@
* <p>
* If the {@code Producer} represents a class, this will invoke the
* constructor annotated {@link javax.inject.Inject} if it exists, or the
- * constructor with no parameters. If the class has interceptors, produce()
- * is responsible for building the interceptors and decorators of the
- * instance.
+ * constructor with no parameters otherwise. If the class has interceptors,
+ * <tt>produce()</tt> is responsible for building the interceptors and
+ * decorators of the instance.
* </p>
* <p>
* If the {@code Producer} represents a producer field or method, this will
@@ -51,7 +51,7 @@
*
* @param ctx The {@link javax.enterprise.context.spi.CreationalContext} to
* use for the produced object
- * @return an instance of the produced object
+ * @return the instance produced
*/
public T produce(CreationalContext<T> ctx);
@@ -61,11 +61,14 @@
* </p>
* <p>
* If the {@code Producer} represents a class, then this operation does
- * nothing. Otherwise, this calls the disposer method, if any, on a
- * contextual instance of the bean that declares the disposer method or
- * performs any additional required cleanup, if any, to destroy state
- * associated with a resource.
+ * nothing.
* </p>
+ * <p>
+ * If the {@code Producer} represents a producer field or method, this
+ * calls the disposer method, if any, on a contextual instance of the
+ * bean that declares the disposer method or performs any additional
+ * required cleanup, if any, to destroy state associated with a resource.
+ * </p>
*
* @param instance The instance to dispose
*/
@@ -73,7 +76,7 @@
/**
* <p>
- * Returns the set of all {@code InjectionPoints} for the producer. If the
+ * Returns the set of all {@code InjectionPoints}. If the
* {@code Producer} represents a class, then this returns returns the set of
* {@code InjectionPoint} objects representing all injected fields, bean
* constructor parameters and initializer method parameters. For a producer
15 years, 1 month
Weld SVN: r4383 - api/trunk/cdi/src/main/java/javax/enterprise/inject/spi.
by weld-commits@lists.jboss.org
Author: gavin.king(a)jboss.com
Date: 2009-10-29 01:23:29 -0400 (Thu, 29 Oct 2009)
New Revision: 4383
Modified:
api/trunk/cdi/src/main/java/javax/enterprise/inject/spi/InjectionPoint.java
Log:
more about InjectionPoint
Modified: api/trunk/cdi/src/main/java/javax/enterprise/inject/spi/InjectionPoint.java
===================================================================
--- api/trunk/cdi/src/main/java/javax/enterprise/inject/spi/InjectionPoint.java 2009-10-29 05:15:11 UTC (rev 4382)
+++ api/trunk/cdi/src/main/java/javax/enterprise/inject/spi/InjectionPoint.java 2009-10-29 05:23:29 UTC (rev 4383)
@@ -28,6 +28,26 @@
* injected field or a parameter of a bean constructor, initializer method,
* producer method, disposer method or observer method.</p>
*
+ * <p>Occasionally, a bean with scope
+ * {@link javax.enterprise.context.Dependent @Dependent} needs to access
+ * metadata relating to the object to which it belongs. The bean may inject an
+ * {@code InjectionPoint} representing the injection point into which the bean
+ * was injected.</p>
+ *
+ * <p>For example, the following producer method creates injectable <tt>Logger</tt>s.
+ * The log category of a <tt>Logger</tt> depends upon the class of the object into
+ * which it is injected.</p>
+ *
+ * <pre>
+ * @Produces
+ * Logger createLogger(InjectionPoint injectionPoint) {
+ * return Logger.getLogger( injectionPoint.getMember().getDeclaringClass().getName() );
+ * }
+ * </pre>
+ *
+ * <p>Only {@linkplain javax.enterprise.context.Dependent dependent} objects, may
+ * obtain information about the injection point to which they belong.</p>
+ *
* @author Gavin King
* @author Pete Muir
*/
15 years, 1 month
Weld SVN: r4382 - api/trunk/cdi/src/main/java/javax/enterprise/inject/spi.
by weld-commits@lists.jboss.org
Author: gavin.king(a)jboss.com
Date: 2009-10-29 01:15:11 -0400 (Thu, 29 Oct 2009)
New Revision: 4382
Modified:
api/trunk/cdi/src/main/java/javax/enterprise/inject/spi/Bean.java
api/trunk/cdi/src/main/java/javax/enterprise/inject/spi/InjectionPoint.java
Log:
doc InjectionPoint
Modified: api/trunk/cdi/src/main/java/javax/enterprise/inject/spi/Bean.java
===================================================================
--- api/trunk/cdi/src/main/java/javax/enterprise/inject/spi/Bean.java 2009-10-29 04:57:00 UTC (rev 4381)
+++ api/trunk/cdi/src/main/java/javax/enterprise/inject/spi/Bean.java 2009-10-29 05:15:11 UTC (rev 4382)
@@ -35,71 +35,75 @@
{
/**
- * Returns the client-visible {@linkplain Type types} of a bean.
+ * Obtains the {@linkplain javax.enterprise.inject bean types} of the bean.
*
- * @return the bean {@linkplain Type types}
+ * @return the {@linkplain javax.enterprise.inject bean types}
*/
public Set<Type> getTypes();
/**
- * Returns the {@linkplain javax.inject.Qualifier qualifiers} of a bean.
+ * Obtains the {@linkplain javax.inject.Qualifier qualifiers} of the bean.
*
* @return the {@linkplain javax.inject.Qualifier qualifiers}
*/
public Set<Annotation> getQualifiers();
/**
- * Returns the {@linkplain javax.enterprise.context scope} of a bean.
+ * Obtains the {@linkplain javax.enterprise.context scope} of the bean.
*
* @return the {@linkplain javax.enterprise.context scope}
*/
public Class<? extends Annotation> getScope();
/**
- * Returns the name of a bean, if it has one.
+ * Obtains the {@linkplain javax.enterprise.inject EL name} of a bean, if it has one.
*
- * @return the name
+ * @return the {@linkplain javax.enterprise.inject EL name}
*/
public String getName();
/**
- * The {@linkplain javax.enterprise.inject.Stereotype stereotypes} applied to
- * this bean
+ * Obtains the {@linkplain javax.enterprise.inject.Stereotype stereotypes}
+ * of the bean.
*
- * @return {@linkplain javax.enterprise.inject.Stereotype stereotypes} if any
+ * @return the set of {@linkplain javax.enterprise.inject.Stereotype stereotypes}
*/
public Set<Class<? extends Annotation>> getStereotypes();
/**
* The bean {@linkplain Class class} of the managed bean or session bean or
- * of the bean that declares the producer method or field
+ * of the bean that declares the producer method or field.
*
- * @return the {@linkplain Class class} of the managed bean
+ * @return the bean {@linkplain Class class}
*/
public Class<?> getBeanClass();
/**
- * Test to see if the bean is an
+ * Determines if the bean is an
* {@linkplain javax.enterprise.inject.Alternative alternative}.
*
- * @return true if the bean is an
- * {@linkplain javax.enterprise.inject.Alternative alternative}
+ * @return <tt>true</tt> if the bean is an
+ * {@linkplain javax.enterprise.inject.Alternative alternative},
+ * and <tt>false</tt> otherwise.
*/
public boolean isAlternative();
/**
- * Determines if the {@code create()} method may sometimes return a null
- * value.
+ * Determines if
+ * {@link javax.enterprise.context.spi.Contextual#create(CreationalContext)}
+ * sometimes return a null value.
*
- * @return true if the {@code create()} method may return a null
+ * @return <tt>true</tt> if the {@code create()} method may return a null
+ * value, and <tt>false</tt> otherwise
*/
public boolean isNullable();
/**
- * A set of {@link InjectionPoint} objects representing injection points of
- * the bean, that will be validated by the container at initialization time.
+ * Obtains the {@link javax.enterprise.inject.spi.InjectionPoint} objects
+ * representing injection points of the bean, that will be validated by the
+ * container at initialization time.
*
- * @return the {@linkplain InjectionPoint injection points} of a bean
+ * @return the set of {@linkplain javax.enterprise.inject.spi.InjectionPoint injection points} of the bean
*/
public Set<InjectionPoint> getInjectionPoints();
Modified: api/trunk/cdi/src/main/java/javax/enterprise/inject/spi/InjectionPoint.java
===================================================================
--- api/trunk/cdi/src/main/java/javax/enterprise/inject/spi/InjectionPoint.java 2009-10-29 04:57:00 UTC (rev 4381)
+++ api/trunk/cdi/src/main/java/javax/enterprise/inject/spi/InjectionPoint.java 2009-10-29 05:15:11 UTC (rev 4382)
@@ -23,12 +23,11 @@
import java.util.Set;
-
/**
+ * <p>Provides access to metadata about an injection point. May represent an
+ * injected field or a parameter of a bean constructor, initializer method,
+ * producer method, disposer method or observer method.</p>
*
- * Provides access to metadata about the injection point into which a dependent
- * object is injected.
- *
* @author Gavin King
* @author Pete Muir
*/
@@ -36,48 +35,63 @@
{
/**
- * Get the declared type of injection point
+ * Get the required type of injection point.
*
- * If the injection point is declared in XML, the type and binding types are
- * determined according to Section 10.8, �Specifying API types and binding
- * types�.
- *
- * @return the declared type of the injection point
+ * @return the required type
*/
public Type getType();
/**
- * Get the declared binding types of the injection point
+ * Get the required qualifiers of the injection point.
*
- * If the injection point is declared in XML, the type and binding types are
- * determined according to Section 10.8, �Specifying API types and binding
- * types�.
- *
- * @return the declared binding types of the injection point
+ * @return the required qualifiers
*/
public Set<Annotation> getQualifiers();
/**
- * Get the Bean object representing the Web Bean that defines the injection
- * point
+ * Get the {@link javax.enterprise.inject.spi.Bean} object representing the
+ * bean that defines the injection point. If the injection point does not
+ * belong to a bean, return a null value.
*
- * @return the Bean object representing the Web Bean that defines the
- * injection point
+ * @return the {@link javax.enterprise.inject.spi.Bean} object representing
+ * bean that defines the injection point, of null if the injection
+ * point does not belong to a bean
*/
public Bean<?> getBean();
/**
- * Get the Field object in the case of field injection, the Method object in
- * the case of method parameter injection or the Constructor object in the
- * case of constructor parameter injection.
+ * Get the {@link java.lang.reflect.Field} object in the case of field
+ * injection, the {@link java.lang.reflect.Method} object in
+ * the case of method parameter injection or the
+ * {@link java.lang.reflect.Constructor} object in the case of constructor
+ * parameter injection.
*
- * @return the member being injected into
+ * @return the member
*/
public Member getMember();
+ /**
+ * Obtain an instance of {@link javax.enterprise.inject.spi.AnnotatedField}
+ * or {@link javax.enterprise.inject.spi.AnnotatedParameter}, depending upon
+ * whether the injection point is an injected field or a constructor/method parameter.
+ *
+ * @return an {@code AnnotatedField} or {@code AnnotatedParameter}
+ */
public Annotated getAnnotated();
+ /**
+ * Determines if the injection point is a decorator delegate injection point.
+ *
+ * @return <tt>true</tt> if the injection point is a decorator delegate injection point,
+ * and <tt>false</tt> otherwise
+ */
public boolean isDelegate();
+ /**
+ * Determines if the injection is a transient field.
+ *
+ * @return <tt>true</tt> if the injection point is a transient field, and <tt>false</tt>
+ * otherwise
+ */
public boolean isTransient();
}
15 years, 1 month