Start line:  
End line:  

Snippet Preview

Snippet HTML Code

Stack Overflow Questions
 package com.fasterxml.jackson.databind.introspect;
 
 
 
Shared base class used for anything on which annotations (included within a AnnotationMap).
public abstract class Annotated
    protected Annotated() { }
    
    public abstract <A extends Annotation> A getAnnotation(Class<A> acls);
    public final <A extends Annotationboolean hasAnnotation(Class<A> acls)
    {
        return getAnnotation(acls) != null;
    }

    
Fluent factory method that will construct a new instance that uses specified instance annotations instead of currently configured ones.
    public abstract Annotated withAnnotations(AnnotationMap fallback);

    
Fluent factory method that will construct a new instance that uses annotations from specified Annotated as fallback annotations
    public final Annotated withFallBackAnnotationsFrom(Annotated annotated) {
        return withAnnotations(AnnotationMap.merge(getAllAnnotations(), annotated.getAllAnnotations()));
    }
    
    
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.
    public abstract AnnotatedElement getAnnotated();
    protected abstract int getModifiers();
    public final boolean isPublic() {
        return Modifier.isPublic(getModifiers());
    }
    public abstract String getName();

    
Full generic type of the annotated element; definition of what exactly this means depends on sub-class.
    public JavaType getType(TypeBindings context) {
        return context.resolveType(getGenericType());
    }

    
Full generic type of the annotated element; definition of what exactly this means depends on sub-class.
    public abstract Type getGenericType();

    
"Raw" type (type-erased class) of the annotated element; definition of what exactly this means depends on sub-class.
    public abstract Class<?> getRawType();
    protected abstract AnnotationMap getAllAnnotations();
New to GrepCode? Check out our FAQ X