public static boolean isRetainedAtRuntime(Class<? extends Annotation> annotationType){
  Retention retention=annotationType.getAnnotation(Retention.class);
  return retention != null && retention.value() == RetentionPolicy.RUNTIME;
}

public static boolean isRetainedAtRuntime ( Class < ? extends Annotation > annotationType ) { Retention retention = annotationType . getAnnotation ( Retention . class ) ; return retention != null && retention . value ( ) == RetentionPolicy . RUNTIME ; }
returns true if the given annotation is retained at runtime .
