public static boolean hasAnnotation ( final List < AnnotationInstance > annotations , final String annotationClaszName ) { final DotName annotationName = DotName . createSimple ( annotationClaszName ) ; for ( final AnnotationInstance annotation : annotations ) { if ( annotation . name ( ) . equals ( annotationName ) ) { return true ; } } return false ; }
Verifies if a list of annotations contains a given one .