Collection<LombokProblem> (@NotNull PsiAnnotation psiAnnotation) { final ProblemValidationSink validationSink = new ProblemValidationSink(); final PsiModifierListOwner psiModifierListOwner; final PsiMethod psiMethod = PsiTreeUtil.getParentOfType(psiAnnotation, PsiMethod.class); if (null != psiMethod) { psiModifierListOwner = psiMethod; } else { psiModifierListOwner = PsiTreeUtil.getParentOfType(psiAnnotation, PsiClass.class); } if (null != psiModifierListOwner) { validateAnnotationOwner(psiModifierListOwner, validationSink); } return validationSink.getProblems(); }