Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## org.springframework.core.type
Class StandardAnnotationMetadata

    java.lang.Object
      org.springframework.core.type.StandardClassMetadata
          org.springframework.core.type.StandardAnnotationMetadata

All Implemented Interfaces:
  AnnotationMetadata, ClassMetadata

    public class StandardAnnotationMetadata

extends StandardClassMetadata
implements AnnotationMetadata

`AnnotationMetadata` implementation that uses standard reflection to introspect a given `Class`.

Since:
  2.5
Author:
  Juergen Hoeller, Mark Fisher

Constructor Summary
`StandardAnnotationMetadata(Class introspectedClass)`

Method Summary
`Map<String,Object>` | `getAnnotationAttributes(String annotationType)` Retrieve the attributes of the annotation of the given type, if any (i.e. if defined on the underlying class).
`Set<String>` | `getAnnotationTypes()` Return the names of all annotation types defined on the underlying class.
`Set<String>` | `getMetaAnnotationTypes(String annotationType)` Return the names of all meta-annotation types defined on the given annotation type of the underlying class.
`boolean` | `hasAnnotation(String annotationType)` Determine whether the underlying class has an annotation of the given type defined.
`boolean` | `hasMetaAnnotation(String annotationType)` Determine whether the underlying class has an annotation that is itself annotated with the meta-annotation of the given type.

Methods inherited from class org.springframework.core.type.StandardClassMetadata
`getClassName, getEnclosingClassName, getInterfaceNames, getIntrospectedClass, getSuperClassName, hasEnclosingClass, hasSuperClass, isAbstract, isConcrete, isIndependent, isInterface`

Methods inherited from class java.lang.Object
`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

Methods inherited from interface org.springframework.core.type.ClassMetadata
`getClassName, getEnclosingClassName, getInterfaceNames, getSuperClassName, hasEnclosingClass, hasSuperClass, isAbstract, isConcrete, isIndependent, isInterface`

Constructor Detail

### StandardAnnotationMetadata

    public StandardAnnotationMetadata(Class introspectedClass)

Method Detail

### getAnnotationTypes

    public Set<String> getAnnotationTypes()

  Description copied from interface: `AnnotationMetadata`
  Return the names of all annotation types defined on the underlying class.

  Specified by:
    `getAnnotationTypes` in interface `AnnotationMetadata`
  Returns:
    the annotation type names

### hasAnnotation

    public boolean hasAnnotation(String annotationType)

  Description copied from interface: `AnnotationMetadata`
  Determine whether the underlying class has an annotation of the given type defined.

  Specified by:
    `hasAnnotation` in interface `AnnotationMetadata`
  Parameters:
    `annotationType` - the annotation type to look for
  Returns:
    whether a matching annotation is defined

### getMetaAnnotationTypes

    public Set<String> getMetaAnnotationTypes(String annotationType)

  Description copied from interface: `AnnotationMetadata`
  Return the names of all meta-annotation types defined on the given annotation type of the underlying class.

  Specified by:
    `getMetaAnnotationTypes` in interface `AnnotationMetadata`
  Returns:
    the meta-annotation type names

### hasMetaAnnotation

    public boolean hasMetaAnnotation(String annotationType)

  Description copied from interface: `AnnotationMetadata`
  Determine whether the underlying class has an annotation that is itself annotated with the meta-annotation of the given type.

  Specified by:
    `hasMetaAnnotation` in interface `AnnotationMetadata`
  Parameters:
    `annotationType` - the meta-annotation type to look for
  Returns:
    whether a matching meta-annotation is defined

### getAnnotationAttributes

    public Map<String,Object> getAnnotationAttributes(String annotationType)

  Description copied from interface: `AnnotationMetadata`
  Retrieve the attributes of the annotation of the given type, if any (i.e. if defined on the underlying class).

  Specified by:
    `getAnnotationAttributes` in interface `AnnotationMetadata`
  Parameters:
    `annotationType` - the annotation type to look for
  Returns:
    a Map of attributes, with the attribute name as key (e.g. "value") and the defined attribute value as Map value. This return value will be `null` if no matching annotation is defined.

Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

Copyright © 2002-2008 The Spring Framework.