com.fasterxml.classmate
Class AnnotationConfiguration.StdConfiguration

java.lang.Object
  extended by com.fasterxml.classmate.AnnotationConfiguration
      extended by com.fasterxml.classmate.AnnotationConfiguration.StdConfiguration
Enclosing class:
AnnotationConfiguration

public static class AnnotationConfiguration.StdConfiguration
extends AnnotationConfiguration

Simple implementation that can be configured with default behavior for unknown annotations, as well as explicit behaviors for enumerated annotation types. Same default is used for both class and member method annotations (constructor, field and static method annotations are never inherited)


Nested Class Summary
 
Nested classes/interfaces inherited from class com.fasterxml.classmate.AnnotationConfiguration
AnnotationConfiguration.StdConfiguration
 
Field Summary
protected  AnnotationInclusion _defaultInclusion
           
protected  HashMap<ClassKey,AnnotationInclusion> _inclusions
           
 
Constructor Summary
AnnotationConfiguration.StdConfiguration(AnnotationInclusion defaultBehavior)
           
 
Method Summary
protected  AnnotationInclusion _inclusionFor(Class<? extends Annotation> annotationType)
           
 AnnotationInclusion getInclusionForClass(Class<? extends Annotation> annotationType)
          Method called to figure out how to handle instances of specified annotation type when used as class annotation.
 AnnotationInclusion getInclusionForConstructor(Class<? extends Annotation> annotationType)
          Method called to figure out how to handle instances of specified annotation type when used as constructor annotation.
 AnnotationInclusion getInclusionForField(Class<? extends Annotation> annotationType)
          Method called to figure out how to handle instances of specified annotation type when used as field annotation.
 AnnotationInclusion getInclusionForMethod(Class<? extends Annotation> annotationType)
          Method called to figure out how to handle instances of specified annotation type when used as method annotation.
 void setInclusion(Class<? extends Annotation> annotationType, AnnotationInclusion incl)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

_defaultInclusion

protected final AnnotationInclusion _defaultInclusion

_inclusions

protected HashMap<ClassKey,AnnotationInclusion> _inclusions
Constructor Detail

AnnotationConfiguration.StdConfiguration

public AnnotationConfiguration.StdConfiguration(AnnotationInclusion defaultBehavior)
Method Detail

getInclusionForClass

public AnnotationInclusion getInclusionForClass(Class<? extends Annotation> annotationType)
Description copied from class: AnnotationConfiguration
Method called to figure out how to handle instances of specified annotation type when used as class annotation.

Specified by:
getInclusionForClass in class AnnotationConfiguration

getInclusionForConstructor

public AnnotationInclusion getInclusionForConstructor(Class<? extends Annotation> annotationType)
Description copied from class: AnnotationConfiguration
Method called to figure out how to handle instances of specified annotation type when used as constructor annotation.

Note that constructor annotations can never be inherited so this just determines between inclusion or non-inclusion.

Specified by:
getInclusionForConstructor in class AnnotationConfiguration

getInclusionForField

public AnnotationInclusion getInclusionForField(Class<? extends Annotation> annotationType)
Description copied from class: AnnotationConfiguration
Method called to figure out how to handle instances of specified annotation type when used as field annotation.

Note that field annotations can never be inherited so this just determines between inclusion or non-inclusion.

Specified by:
getInclusionForField in class AnnotationConfiguration

getInclusionForMethod

public AnnotationInclusion getInclusionForMethod(Class<? extends Annotation> annotationType)
Description copied from class: AnnotationConfiguration
Method called to figure out how to handle instances of specified annotation type when used as method annotation.

Note that method annotations can be inherited for member methods, but not for static methods; for static methods thereby this just determines between inclusion and non-inclusion.

Specified by:
getInclusionForMethod in class AnnotationConfiguration

setInclusion

public void setInclusion(Class<? extends Annotation> annotationType,
                         AnnotationInclusion incl)

_inclusionFor

protected AnnotationInclusion _inclusionFor(Class<? extends Annotation> annotationType)


Copyright © 2011 fasterxml.com. All Rights Reserved.