org.jboss.webbeans.introspector.jlr
Class AnnotatedAnnotationImpl<T extends java.lang.annotation.Annotation>
java.lang.Object
org.jboss.webbeans.introspector.jlr.AbstractAnnotatedItem<T,java.lang.Class<T>>
org.jboss.webbeans.introspector.jlr.AbstractAnnotatedType<T>
org.jboss.webbeans.introspector.jlr.AnnotatedAnnotationImpl<T>
- Type Parameters:
T
-
- All Implemented Interfaces:
- AnnotatedAnnotation<T>, AnnotatedItem<T,java.lang.Class<T>>, AnnotatedType<T>
public class AnnotatedAnnotationImpl<T extends java.lang.annotation.Annotation>
- extends AbstractAnnotatedType<T>
- implements AnnotatedAnnotation<T>
Represents an annotated annotation
This class is immutable and therefore threadsafe
- Author:
- Pete Muir
Method Summary |
java.util.Set<AnnotatedMethod<?>> |
getAnnotatedMembers(java.lang.Class<? extends java.lang.annotation.Annotation> annotationType)
Returns the annotated members with a given annotation type
If the annotated members are null, they are initialized first. |
java.lang.Class<T> |
getDelegate()
|
|
getMember(java.lang.String memberName,
AnnotatedClass<A> expectedType)
Get an annotation member by name |
java.util.Set<AnnotatedMethod<?>> |
getMembers()
Gets all members of the annotation
Initializes the members first if they are null |
static
|
of(java.lang.Class<A> annotationType,
ClassTransformer classTransformer)
|
java.lang.String |
toString()
Gets a string representation of the annotation |
AnnotatedAnnotation<T> |
wrap(java.util.Set<java.lang.annotation.Annotation> annotations)
|
Methods inherited from class org.jboss.webbeans.introspector.jlr.AbstractAnnotatedItem |
equals, getActualTypeArguments, getAnnotation, getAnnotationsAsSet, getAnnotationStore, getBindings, getBindingsAsArray, getDeclaredMetaAnnotations, getFlattenedTypeHierarchy, getMetaAnnotations, getMetaAnnotationsAsArray, getRawType, getType, hashCode, isAnnotationPresent, isAssignableFrom, isAssignableFrom, isDeclaredAnnotationPresent, isParameterizedType, isProxyable |
Methods inherited from class java.lang.Object |
clone, finalize, getClass, notify, notifyAll, wait, wait, wait |
Methods inherited from interface org.jboss.webbeans.introspector.AnnotatedItem |
getActualTypeArguments, getAnnotation, getAnnotationsAsSet, getAnnotationStore, getBindings, getBindingsAsArray, getDeclaredMetaAnnotations, getFlattenedTypeHierarchy, getMetaAnnotations, getMetaAnnotationsAsArray, getName, getType, isAnnotationPresent, isAssignableFrom, isAssignableFrom, isDeclaredAnnotationPresent, isFinal, isParameterizedType, isProxyable, isPublic, isStatic |
AnnotatedAnnotationImpl
protected AnnotatedAnnotationImpl(java.lang.Class<T> annotationType,
ClassTransformer classTransformer)
- Constructor
Initializes the superclass with the built annotation map
- Parameters:
annotationType
- The annotation type
of
public static <A extends java.lang.annotation.Annotation> AnnotatedAnnotation<A> of(java.lang.Class<A> annotationType,
ClassTransformer classTransformer)
getMembers
public java.util.Set<AnnotatedMethod<?>> getMembers()
- Gets all members of the annotation
Initializes the members first if they are null
- Specified by:
getMembers
in interface AnnotatedAnnotation<T extends java.lang.annotation.Annotation>
- Returns:
- The set of abstracted members
- See Also:
AnnotatedAnnotation.getMembers()
getAnnotatedMembers
public java.util.Set<AnnotatedMethod<?>> getAnnotatedMembers(java.lang.Class<? extends java.lang.annotation.Annotation> annotationType)
- Returns the annotated members with a given annotation type
If the annotated members are null, they are initialized first.
- Specified by:
getAnnotatedMembers
in interface AnnotatedAnnotation<T extends java.lang.annotation.Annotation>
- Parameters:
annotationType
- The annotation type to match
- Returns:
- The set of abstracted members with the given annotation type
present. An empty set is returned if no matches are found
- See Also:
AnnotatedAnnotation.getAnnotatedMembers(Class)
getMember
public <A> AnnotatedMethod<A> getMember(java.lang.String memberName,
AnnotatedClass<A> expectedType)
- Description copied from interface:
AnnotatedAnnotation
- Get an annotation member by name
- Specified by:
getMember
in interface AnnotatedAnnotation<T extends java.lang.annotation.Annotation>
- Returns:
toString
public java.lang.String toString()
- Gets a string representation of the annotation
- Overrides:
toString
in class AbstractAnnotatedType<T extends java.lang.annotation.Annotation>
- Returns:
- A string representation
getDelegate
public java.lang.Class<T> getDelegate()
- Specified by:
getDelegate
in class AbstractAnnotatedItem<T extends java.lang.annotation.Annotation,java.lang.Class<T extends java.lang.annotation.Annotation>>
wrap
public AnnotatedAnnotation<T> wrap(java.util.Set<java.lang.annotation.Annotation> annotations)
Copyright © 2011. All Rights Reserved.