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();
}