Class BackedAnnotatedParameter<X>
- java.lang.Object
-
- org.jboss.weld.annotated.slim.BaseAnnotated
-
- org.jboss.weld.annotated.slim.backed.BackedAnnotated
-
- org.jboss.weld.annotated.slim.backed.BackedAnnotatedParameter<X>
-
- All Implemented Interfaces:
Serializable,Annotated,AnnotatedParameter<X>
public class BackedAnnotatedParameter<X> extends BackedAnnotated implements AnnotatedParameter<X>, Serializable
- See Also:
- Serialized Form
-
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description booleanequals(Object obj)static <X> List<AnnotatedParameter<X>>forExecutable(Executable executable, BackedAnnotatedCallable<X,?> declaringCallable, SharedObjectCache cache)protected AnnotatedElementgetAnnotatedElement()<T extends Annotation>
TgetAnnotation(Class<T> annotationType)Get program element annotation of a certain annotation type.Set<Annotation>getAnnotations()Get all annotations of the program element.BackedAnnotatedCallable<X,?>getDeclaringCallable()Get the declaring method or constructor.ParametergetJavaParameter()Get the underlyingParameter.intgetPosition()Get the position of the parameter in the method or constructor argument list.protected ReflectionCachegetReflectionCache()inthashCode()booleanisAnnotationPresent(Class<? extends Annotation> annotationType)Determine if the program element has an annotation of a certain annotation type.static <X> AnnotatedParameter<X>of(Parameter parameter, int position, BackedAnnotatedCallable<X,?> declaringCallable, SharedObjectCache sharedObjectCache)StringtoString()-
Methods inherited from class org.jboss.weld.annotated.slim.backed.BackedAnnotated
getTypeClosure, initTypeClosure
-
Methods inherited from class org.jboss.weld.annotated.slim.BaseAnnotated
getBaseType
-
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
-
Methods inherited from interface javax.enterprise.inject.spi.Annotated
getBaseType, getTypeClosure
-
Methods inherited from interface javax.enterprise.inject.spi.AnnotatedParameter
getAnnotations
-
-
-
-
Method Detail
-
forExecutable
public static <X> List<AnnotatedParameter<X>> forExecutable(Executable executable, BackedAnnotatedCallable<X,?> declaringCallable, SharedObjectCache cache)
-
of
public static <X> AnnotatedParameter<X> of(Parameter parameter, int position, BackedAnnotatedCallable<X,?> declaringCallable, SharedObjectCache sharedObjectCache)
-
getPosition
public int getPosition()
Description copied from interface:AnnotatedParameterGet the position of the parameter in the method or constructor argument list.
- Specified by:
getPositionin interfaceAnnotatedParameter<X>- Returns:
- the position of the parameter
-
getJavaParameter
public Parameter getJavaParameter()
Description copied from interface:AnnotatedParameterGet the underlyingParameter.- Specified by:
getJavaParameterin interfaceAnnotatedParameter<X>- Returns:
- the
Parameter
-
getDeclaringCallable
public BackedAnnotatedCallable<X,?> getDeclaringCallable()
Description copied from interface:AnnotatedParameterGet the declaring method or constructor.
- Specified by:
getDeclaringCallablein interfaceAnnotatedParameter<X>- Returns:
- the declaring callable
-
getAnnotation
public <T extends Annotation> T getAnnotation(Class<T> annotationType)
Description copied from interface:AnnotatedGet program element annotation of a certain annotation type. The behavior of this method is intended to be the same behavior as
AnnotatedElement.getAnnotation(Class), where repeatable annotations are not supported.- Specified by:
getAnnotationin interfaceAnnotated- Type Parameters:
T- the type of the annotation- Parameters:
annotationType- the class of the annotation type- Returns:
- the first program element annotation of the given annotation type, or a null value
-
getAnnotations
public Set<Annotation> getAnnotations()
Description copied from interface:AnnotatedGet all annotations of the program element.
- Specified by:
getAnnotationsin interfaceAnnotated- Overrides:
getAnnotationsin classBackedAnnotated- Returns:
- all annotations of the program element, or an empty set if no annotations are present
-
getAnnotatedElement
protected AnnotatedElement getAnnotatedElement()
- Specified by:
getAnnotatedElementin classBackedAnnotated
-
isAnnotationPresent
public boolean isAnnotationPresent(Class<? extends Annotation> annotationType)
Description copied from interface:AnnotatedDetermine if the program element has an annotation of a certain annotation type. The behavior of this method is similar to
AnnotatedElement.isAnnotationPresent(Class)for the underlying program element.- Specified by:
isAnnotationPresentin interfaceAnnotated- Parameters:
annotationType- the annotation type to check for- Returns:
- true if the program element has an annotation of the given annotation type, or false otherwise
-
getReflectionCache
protected ReflectionCache getReflectionCache()
- Specified by:
getReflectionCachein classBackedAnnotated
-
-