public class AnnotationDescriptor<A extends java.lang.annotation.Annotation>
extends java.lang.Object
implements java.io.Serializable
Annotation
instance
and the values of its elements.
The "elements" we're talking about are the annotation attributes,
not its targets (the term "element" is used ambiguously
in Java's annotations documentation).Modifier and Type | Class and Description |
---|---|
static class |
AnnotationDescriptor.Builder<S extends java.lang.annotation.Annotation> |
Constructor and Description |
---|
AnnotationDescriptor(A annotation) |
AnnotationDescriptor(AnnotationDescriptor<A> descriptor) |
Modifier and Type | Method and Description |
---|---|
boolean |
equals(java.lang.Object obj) |
A |
getAnnotation() |
java.lang.Object |
getAttribute(java.lang.String attributeName) |
<T> T |
getAttribute(java.lang.String attributeName,
java.lang.Class<T> attributeType) |
java.util.Map<java.lang.String,java.lang.Object> |
getAttributes() |
<T> T |
getMandatoryAttribute(java.lang.String attributeName,
java.lang.Class<T> attributeType) |
java.lang.Class<A> |
getType() |
int |
hashCode()
Calculates the hash code of this annotation descriptor as described in
Annotation.hashCode() . |
java.lang.String |
toString() |
public AnnotationDescriptor(A annotation)
public AnnotationDescriptor(AnnotationDescriptor<A> descriptor)
public java.lang.Class<A> getType()
public java.util.Map<java.lang.String,java.lang.Object> getAttributes()
public <T> T getMandatoryAttribute(java.lang.String attributeName, java.lang.Class<T> attributeType)
public <T> T getAttribute(java.lang.String attributeName, java.lang.Class<T> attributeType)
public java.lang.Object getAttribute(java.lang.String attributeName)
public A getAnnotation()
public boolean equals(java.lang.Object obj)
equals
in class java.lang.Object
public int hashCode()
Annotation.hashCode()
.hashCode
in class java.lang.Object
Annotation.hashCode()
public java.lang.String toString()
toString
in class java.lang.Object
Copyright © 2007-2022 Red Hat, Inc. All Rights Reserved