org.jboss.webbeans.introspector.jlr
Class AnnotatedAnnotationImpl<T extends java.lang.annotation.Annotation>

java.lang.Object
  extended by org.jboss.webbeans.introspector.jlr.AbstractAnnotatedItem<T,java.lang.Class<T>>
      extended by org.jboss.webbeans.introspector.jlr.AbstractAnnotatedType<T>
          extended by 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

Nested Class Summary
 
Nested classes/interfaces inherited from class org.jboss.webbeans.introspector.jlr.AbstractAnnotatedItem
AbstractAnnotatedItem.AnnotationMap
 
Field Summary
 
Fields inherited from interface org.jboss.webbeans.introspector.AnnotatedItem
MAPPED_METAANNOTATIONS
 
Constructor Summary
AnnotatedAnnotationImpl(java.lang.Class<T> annotationType)
          Constructor Initializes the superclass with the built annotation map
 
Method Summary
 java.lang.reflect.Type[] getActualTypeArguments()
          Gets the actual type arguments
 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.
protected  java.lang.Class<T> getDelegate()
           
 java.util.Set<AnnotatedMethod<?>> getMembers()
          Gets all members of the annotation Initializes the members first if they are null
 java.lang.Class<T> getType()
          Gets the type of the annotation
 java.lang.String toDetailedString()
           
 java.lang.String toString()
          Gets a string representation of the annotation
 
Methods inherited from class org.jboss.webbeans.introspector.jlr.AbstractAnnotatedType
getName, getSuperclass, isFinal, isStatic
 
Methods inherited from class org.jboss.webbeans.introspector.jlr.AbstractAnnotatedItem
buildAnnotationMap, buildAnnotationMap, equals, getAnnotation, getAnnotationMap, getAnnotations, getBindingTypes, getBindingTypesAsArray, getMetaAnnotations, getMetaAnnotationsAsArray, getParameterValues, getParameterValues, hashCode, isAnnotationPresent, isAssignableFrom, isAssignableFrom, isProxyable
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
 
Methods inherited from interface org.jboss.webbeans.introspector.AnnotatedType
getSuperclass
 
Methods inherited from interface org.jboss.webbeans.introspector.AnnotatedItem
getAnnotation, getAnnotations, getBindingTypes, getBindingTypesAsArray, getMetaAnnotations, getMetaAnnotationsAsArray, getName, isAnnotationPresent, isAssignableFrom, isAssignableFrom, isFinal, isProxyable, isStatic
 

Constructor Detail

AnnotatedAnnotationImpl

public AnnotatedAnnotationImpl(java.lang.Class<T> annotationType)
Constructor Initializes the superclass with the built annotation map

Parameters:
annotationType - The annotation type
Method Detail

getActualTypeArguments

public java.lang.reflect.Type[] getActualTypeArguments()
Gets the actual type arguments

Specified by:
getActualTypeArguments in interface AnnotatedItem<T extends java.lang.annotation.Annotation,java.lang.Class<T extends java.lang.annotation.Annotation>>
Returns:
The type arguments
See Also:
AnnotatedItem.getActualTypeArguments()

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

getType

public java.lang.Class<T> getType()
Gets the type of the annotation

Specified by:
getType in interface AnnotatedItem<T extends java.lang.annotation.Annotation,java.lang.Class<T extends java.lang.annotation.Annotation>>
Returns:
The type of the element
See Also:
AnnotatedItem.getType()

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)

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

toDetailedString

public java.lang.String toDetailedString()
Overrides:
toDetailedString in class AbstractAnnotatedType<T extends java.lang.annotation.Annotation>

getDelegate

protected 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>>


Copyright © 2008. All Rights Reserved.