Class Annotated
- java.lang.Object
-
- org.codehaus.jackson.map.introspect.Annotated
-
- Direct Known Subclasses:
AnnotatedClass,AnnotatedMember
public abstract class Annotated extends java.lang.ObjectShared base class used for anything on which annotations (included within aAnnotationMap).
-
-
Constructor Summary
Constructors Modifier Constructor Description protectedAnnotated()
-
Method Summary
All Methods Instance Methods Abstract Methods Concrete Methods Modifier and Type Method Description protected abstract AnnotationMapgetAllAnnotations()abstract java.lang.reflect.AnnotatedElementgetAnnotated()Method that can be used to find actual JDK element that this instance represents.abstract <A extends java.lang.annotation.Annotation>
AgetAnnotation(java.lang.Class<A> acls)abstract java.lang.reflect.TypegetGenericType()Full generic type of the annotated element; definition of what exactly this means depends on sub-class.protected abstract intgetModifiers()abstract java.lang.StringgetName()abstract java.lang.Class<?>getRawType()"Raw" type (type-erased class) of the annotated element; definition of what exactly this means depends on sub-class.JavaTypegetType(TypeBindings context)Full generic type of the annotated element; definition of what exactly this means depends on sub-class.<A extends java.lang.annotation.Annotation>
booleanhasAnnotation(java.lang.Class<A> acls)booleanisPublic()abstract AnnotatedwithAnnotations(AnnotationMap fallback)Fluent factory method that will construct a new instance that uses specified instance annotations instead of currently configured ones.AnnotatedwithFallBackAnnotationsFrom(Annotated annotated)Fluent factory method that will construct a new instance that uses annotations from specifiedAnnotatedas fallback annotations
-
-
-
Method Detail
-
getAnnotation
public abstract <A extends java.lang.annotation.Annotation> A getAnnotation(java.lang.Class<A> acls)
-
hasAnnotation
public final <A extends java.lang.annotation.Annotation> boolean hasAnnotation(java.lang.Class<A> acls)
-
withAnnotations
public abstract Annotated withAnnotations(AnnotationMap fallback)
Fluent factory method that will construct a new instance that uses specified instance annotations instead of currently configured ones.- Since:
- 1.9
-
withFallBackAnnotationsFrom
public final Annotated withFallBackAnnotationsFrom(Annotated annotated)
Fluent factory method that will construct a new instance that uses annotations from specifiedAnnotatedas fallback annotations- Since:
- 1.9
-
getAnnotated
public abstract java.lang.reflect.AnnotatedElement getAnnotated()
Method that can be used to find actual JDK element that this instance represents. It is non-null, except for method/constructor parameters which do not have a JDK counterpart.
-
getModifiers
protected abstract int getModifiers()
-
isPublic
public final boolean isPublic()
-
getName
public abstract java.lang.String getName()
-
getType
public JavaType getType(TypeBindings context)
Full generic type of the annotated element; definition of what exactly this means depends on sub-class.
-
getGenericType
public abstract java.lang.reflect.Type getGenericType()
Full generic type of the annotated element; definition of what exactly this means depends on sub-class.- Since:
- 1.5
-
getRawType
public abstract java.lang.Class<?> getRawType()
"Raw" type (type-erased class) of the annotated element; definition of what exactly this means depends on sub-class.- Since:
- 1.5
-
getAllAnnotations
protected abstract AnnotationMap getAllAnnotations()
-
-