@Override
  public @NotNull IntentionPreviewInfo generatePreview(@NotNull Project project, @NotNull Editor editor, @NotNull PsiFile file) {
    final PsiElement startElement = getStartElement();
    final PsiElement copy = PsiTreeUtil.findSameElementInCopy(startElement, file);
    final OverrideOrImplementOptions options = new OverrideOrImplementOptions() {
      @Override
      public boolean isInsertOverrideWherePossible() {
        return true;
      }
    };
    final Collection<CandidateInfo> overrideImplement;
    final PsiClass aClass;
    if (copy instanceof PsiEnumConstant enumConstant) {
      final PsiClass containingClass = enumConstant.getContainingClass();
      if (containingClass == null) return IntentionPreviewInfo.EMPTY;
      aClass = enumConstant.getOrCreateInitializingClass();
      overrideImplement = OverrideImplementExploreUtil.getMapToOverrideImplement(containingClass, true, false).values();
    }
    else {
      if (!(copy instanceof PsiClass psiClass)) return IntentionPreviewInfo.EMPTY;
      aClass = psiClass;
      overrideImplement = OverrideImplementExploreUtil.getMethodsToOverrideImplement(psiClass, true);
    }
    final List<PsiMethodMember> members = filterNonDefaultMethodMembers(overrideImplement);
    OverrideImplementUtil.overrideOrImplementMethodsInRightPlace(editor, aClass, members, options);
    return IntentionPreviewInfo.DIFF;
  }
@Override
  public @NotNull IntentionPreviewInfo generatePreview(@NotNull Project project, @NotNull Editor editor, @NotNull PsiFile file)