boolean (@NotNull PsiClass aClass, @NotNull String annotationFQN) { Map<String, PsiClass> classMap = ClassUtil.getSuperClassesWithCache(aClass); for (PsiClass psiClass : classMap.values()) { PsiModifierList modifierList = psiClass.getModifierList(); if (modifierList != null) { if (modifierList.hasAnnotation(annotationFQN)) { return true; } } } return false; }