PsiClass (@NotNull PsiAnnotation annotation) { PsiAnnotationMemberValue containerRef = PsiImplUtil.findAttributeValue(annotation, null); if (!(containerRef instanceof PsiClassObjectAccessExpression)) return null; PsiType containerType = ((PsiClassObjectAccessExpression)containerRef).getOperand().getType(); if (!(containerType instanceof PsiClassType)) return null; return ((PsiClassType)containerType).resolve(); }