void (@NotNull Project project, @NotNull PsiElement element, @NotNull ModPsiUpdater updater) { PsiSwitchStatement statement = PsiTreeUtil.getParentOfType(element, PsiSwitchStatement.class); if (statement == null) return; SwitchReplacer replacer = ContainerUtil.find(findSwitchReplacers(statement, Integer.MAX_VALUE), t -> t.getType() == myReplacementType); if (replacer == null) return; replacer.replace(statement); }