void (@NotNull PsiClass psiClass) { final PsiMethod equalsMethod = findPublicNonStaticMethod(psiClass, "equals", PsiTypes.booleanType(), PsiType.getJavaLangObject(psiClass.getManager(), psiClass.getResolveScope())); if (null != equalsMethod) { equalsMethod.delete(); } final PsiMethod hashCodeMethod = findPublicNonStaticMethod(psiClass, "hashCode", PsiTypes.intType()); if (null != hashCodeMethod) { hashCodeMethod.delete(); } addAnnotation(psiClass, LombokClassNames.EQUALS_AND_HASHCODE); }