RenameToIgnoredFix (@NotNull PsiNamedElement element, boolean useElementNameAsSuffix) { if (element instanceof PsiVariable variable && canBeUnnamed(variable) && !VariableAccessUtils.variableIsUsed(variable, PsiUtil.getVariableCodeBlock(variable, null))) { return new RenameToIgnoredFix(variable, "_"); } String baseName = ""; if (useElementNameAsSuffix) { String elementName = element.getName(); if (elementName != null) { baseName = StringUtil.capitalize(elementName); } } return new RenameToIgnoredFix(element, JavaCodeStyleManager.getInstance(element.getProject()) .suggestUniqueVariableName(PREFIX + baseName, element, true)); }