Class EnhancedAnnotatedParameterImpl<T,X>
- java.lang.Object
-
- org.jboss.weld.annotated.enhanced.jlr.AbstractEnhancedAnnotated<T,Object>
-
- org.jboss.weld.annotated.enhanced.jlr.EnhancedAnnotatedParameterImpl<T,X>
-
- Type Parameters:
T-
- All Implemented Interfaces:
Annotated,AnnotatedParameter<X>,EnhancedAnnotated<T,Object>,EnhancedAnnotatedParameter<T,X>
public class EnhancedAnnotatedParameterImpl<T,X> extends AbstractEnhancedAnnotated<T,Object> implements EnhancedAnnotatedParameter<T,X>
Represents a parameter This class is immutable and therefore threadsafe- Author:
- Pete Muir
-
-
Field Summary
-
Fields inherited from interface org.jboss.weld.annotated.enhanced.EnhancedAnnotated
MAPPED_DECLARED_METAANNOTATIONS, MAPPED_METAANNOTATIONS
-
-
Constructor Summary
Constructors Modifier Constructor Description protectedEnhancedAnnotatedParameterImpl(AnnotatedParameter<X> annotatedParameter, EnhancedAnnotatedCallable<?,X,?> declaringMember, Map<Class<? extends Annotation>,Annotation> annotationMap, ClassTransformer classTransformer)Constructor
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description AnnotatedCallable<X>getDeclaringCallable()Get the declaring method or constructor.EnhancedAnnotatedCallable<?,X,?>getDeclaringEnhancedCallable()EnhancedAnnotatedType<X>getDeclaringType()ObjectgetDelegate()StringgetName()Gets the name of the parameterPackagegetPackage()intgetPosition()Get the position of the parameter in the method or constructor argument list.booleanisFinal()Indicates if the parameter is finalbooleanisGeneric()booleanisPackagePrivate()booleanisPrivate()booleanisPublic()Indicates if this annotated item is publicbooleanisStatic()Indicates if the parameter is staticstatic <T,X>
EnhancedAnnotatedParameter<T,X>of(AnnotatedParameter<X> annotatedParameter, EnhancedAnnotatedCallable<?,X,?> declaringMember, ClassTransformer classTransformer)AnnotatedParameter<X>slim()Returns a lightweight implementation ofAnnotatedParameterwith minimal memory footprint.StringtoString()Gets a string representation of the parameter-
Methods inherited from class org.jboss.weld.annotated.enhanced.jlr.AbstractEnhancedAnnotated
addMetaAnnotations, buildAnnotationMap, getActualTypeArguments, getAnnotation, getAnnotations, getBaseType, getBindingsAsArray, getInterfaceClosure, getJavaClass, getMetaAnnotations, getQualifiers, getTypeClosure, isAnnotationPresent, isParameterizedType, isPrimitive, processMetaAnnotations, processMetaAnnotations, processMetaAnnotations
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
-
Methods inherited from interface javax.enterprise.inject.spi.Annotated
getAnnotation, getAnnotations, getBaseType, getTypeClosure, isAnnotationPresent
-
Methods inherited from interface javax.enterprise.inject.spi.AnnotatedParameter
getAnnotations, getJavaParameter
-
Methods inherited from interface org.jboss.weld.annotated.enhanced.EnhancedAnnotated
getActualTypeArguments, getBindingsAsArray, getInterfaceClosure, getJavaClass, getMetaAnnotations, getQualifiers, isParameterizedType, isPrimitive
-
-
-
-
Constructor Detail
-
EnhancedAnnotatedParameterImpl
protected EnhancedAnnotatedParameterImpl(AnnotatedParameter<X> annotatedParameter, EnhancedAnnotatedCallable<?,X,?> declaringMember, Map<Class<? extends Annotation>,Annotation> annotationMap, ClassTransformer classTransformer)
Constructor- Parameters:
annotations- The annotations arraytype- The type of the parameter
-
-
Method Detail
-
of
public static <T,X> EnhancedAnnotatedParameter<T,X> of(AnnotatedParameter<X> annotatedParameter, EnhancedAnnotatedCallable<?,X,?> declaringMember, ClassTransformer classTransformer)
-
isFinal
public boolean isFinal()
Indicates if the parameter is final- Specified by:
isFinalin interfaceEnhancedAnnotated<T,X>- Returns:
- True if final, false otherwise
- See Also:
EnhancedAnnotated.isFinal()
-
isStatic
public boolean isStatic()
Indicates if the parameter is static- Specified by:
isStaticin interfaceEnhancedAnnotated<T,X>- Returns:
- True if static, false otherwise
- See Also:
EnhancedAnnotated.isStatic()
-
isPublic
public boolean isPublic()
Description copied from interface:EnhancedAnnotatedIndicates if this annotated item is public- Specified by:
isPublicin interfaceEnhancedAnnotated<T,X>- Returns:
- if public, returns true
-
isPrivate
public boolean isPrivate()
- Specified by:
isPrivatein interfaceEnhancedAnnotated<T,X>
-
isPackagePrivate
public boolean isPackagePrivate()
- Specified by:
isPackagePrivatein interfaceEnhancedAnnotated<T,X>
-
isGeneric
public boolean isGeneric()
- Specified by:
isGenericin interfaceEnhancedAnnotated<T,X>
-
getPackage
public Package getPackage()
- Specified by:
getPackagein interfaceEnhancedAnnotated<T,X>
-
getName
public String getName()
Gets the name of the parameter- Specified by:
getNamein interfaceEnhancedAnnotated<T,X>- Returns:
- The name
- Throws:
IllegalArgumentException- (not supported)- See Also:
EnhancedAnnotated.getName()
-
toString
public String toString()
Gets a string representation of the parameter
-
getDeclaringCallable
public AnnotatedCallable<X> getDeclaringCallable()
Description copied from interface:AnnotatedParameterGet the declaring method or constructor.
- Specified by:
getDeclaringCallablein interfaceAnnotatedParameter<T>- Returns:
- the declaring callable
-
getDeclaringEnhancedCallable
public EnhancedAnnotatedCallable<?,X,?> getDeclaringEnhancedCallable()
- Specified by:
getDeclaringEnhancedCallablein interfaceEnhancedAnnotatedParameter<T,X>
-
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<T>- Returns:
- the position of the parameter
-
getDelegate
public Object getDelegate()
- Specified by:
getDelegatein classAbstractEnhancedAnnotated<T,Object>
-
getDeclaringType
public EnhancedAnnotatedType<X> getDeclaringType()
- Specified by:
getDeclaringTypein interfaceEnhancedAnnotatedParameter<T,X>
-
slim
public AnnotatedParameter<X> slim()
Description copied from interface:EnhancedAnnotatedParameterReturns a lightweight implementation ofAnnotatedParameterwith minimal memory footprint.- Specified by:
slimin interfaceEnhancedAnnotated<T,X>- Specified by:
slimin interfaceEnhancedAnnotatedParameter<T,X>- Returns:
- the slim version of this
AnnotatedParameter
-
-