public abstract class AnnotationLiteral<T extends java.lang.annotation.Annotation>
extends java.lang.Object
implements java.lang.annotation.Annotation, java.io.Serializable
Annotation current = new AnnotationLiteral<Current>() {}
Annotation named = new AnnotationLiteral<Named>() {
public String name() { return "my-name"; }
}
| Modifier | Constructor and Description |
|---|---|
protected |
AnnotationLiteral() |
| Modifier and Type | Method and Description |
|---|---|
java.lang.Class<? extends java.lang.annotation.Annotation> |
annotationType() |
boolean |
equals(java.lang.Object o) |
int |
hashCode() |
java.lang.String |
toString() |
public java.lang.Class<? extends java.lang.annotation.Annotation> annotationType()
annotationType in interface java.lang.annotation.Annotationpublic boolean equals(java.lang.Object o)
equals in interface java.lang.annotation.Annotationequals in class java.lang.Objectpublic int hashCode()
hashCode in interface java.lang.annotation.AnnotationhashCode in class java.lang.Objectpublic java.lang.String toString()
toString in interface java.lang.annotation.AnnotationtoString in class java.lang.Object