public static < A extends Annotation > boolean isDeclaredAnnotationPresent ( Class < ? > onClass , Class < A > annotationType ) { return getDeclaredAnnotation ( onClass , annotationType ) != null ; }
Is the declared annotation present ignoring any inherited annotations