boolean (@NotNull PsiModifierListOwner psiModifierListOwner, ProblemSink validationSink) { final boolean hasBuilder = PsiAnnotationSearchUtil.isAnnotatedWith(psiModifierListOwner, LombokClassNames.BUILDER); final boolean hasSuperBuilder = PsiAnnotationSearchUtil.isAnnotatedWith(psiModifierListOwner, LombokClassNames.SUPER_BUILDER); if (!hasBuilder && !hasSuperBuilder) { validationSink.addWarningMessage("inspection.message.jacksonized.requires.builder.superbuilder"); } if (hasBuilder && hasSuperBuilder) { validationSink.addErrorMessage("inspection.message.jacksonized.cannot.process.both.builder.superbuilder"); validationSink.markFailed(); } boolean isAbstract = psiModifierListOwner.hasModifierProperty(PsiModifier.ABSTRACT); if (isAbstract) { validationSink.addErrorMessage("inspection.message.jacksonized.builder.on.abstract.classes"); validationSink.markFailed(); } final boolean hasJsonDeserialize = PsiAnnotationSearchUtil.isAnnotatedWith(psiModifierListOwner, "com.fasterxml.jackson.databind.annotation.JsonDeserialize"); if (hasJsonDeserialize) { validationSink.addErrorMessage("inspection.message.jacksonized.jsondeserialize.already.exists"); validationSink.markFailed(); } return validationSink.success(); }