@NotNull
    PsiSwitchLabelStatement addLabelAfter(@NotNull PsiCaseLabelElement labelElement, @NotNull PsiSwitchLabelStatement labelStatement) {
      Project project = myCodeBlock.getProject();
      PsiElementFactory factory = JavaPsiFacade.getElementFactory(project);
      PsiSwitchLabelStatement newLabel;
      if (labelElement instanceof PsiDefaultCaseLabelElement) {
        newLabel = (PsiSwitchLabelStatement)factory.createStatementFromText("default:", null);
      }
      else {
        PsiElement defaultElement = SwitchUtils.findDefaultElement(labelStatement);
        if (defaultElement != null) {
          return addLabelAfter((PsiCaseLabelElement)defaultElement, labelStatement);
        }
        newLabel =
          (PsiSwitchLabelStatement)factory.createStatementFromText("case 1" + (myGuard == null ? "" : " when " + myGuard.getText()) + ":", null);
        Objects.requireNonNull(newLabel.getCaseLabelElementList()).getElements()[0].replace(labelElement);
      }

      newLabel = (PsiSwitchLabelStatement)myCodeBlock.addAfter(newLabel, myLastStatement);
      newLabel = (PsiSwitchLabelStatement)CodeStyleManager.getInstance(project).reformat(newLabel);

      labelElement.delete();
      return newLabel;
    }
@NotNull
    PsiSwitchLabelStatement addLabelAfter(@NotNull PsiCaseLabelElement labelElement, @NotNull PsiSwitchLabelStatement labelStatement)