LocalQuickFix[] (@NotNull UClass uClass, boolean visitLambdaMissing, boolean visitClassMissing) { if (!uClass.getLang().is(JavaLanguage.INSTANCE)) return LocalQuickFix.EMPTY_ARRAY; final String fixName; final String[] methodsToInsert; if (visitLambdaMissing && visitClassMissing) { fixName = DevKitBundle.message("inspections.unsafe.return.insert.visit.lambda.expression.and.class.methods"); methodsToInsert = new String[]{EMPTY_VISIT_LAMBDA_METHOD, EMPTY_VISIT_CLASS_METHOD}; } else if (visitLambdaMissing) { fixName = DevKitBundle.message("inspections.unsafe.return.insert.visit.lambda.expression"); methodsToInsert = new String[]{EMPTY_VISIT_LAMBDA_METHOD}; } else { fixName = DevKitBundle.message("inspections.unsafe.return.insert.visit.class.method"); methodsToInsert = new String[]{EMPTY_VISIT_CLASS_METHOD}; } return new LocalQuickFix[]{new MySkipVisitFix(fixName, methodsToInsert)}; }