@Override
  protected @Nullable Presentation getPresentation(@NotNull ActionContext context, @NotNull PsiElement element) {
    if (!(context.file() instanceof PsiJavaFile)) return null;
    final Set<PsiClassType> unhandled = new HashSet<>();
    if (collectExceptions(unhandled, element) == null) return null;
    return switch (myProcessHierarchy) {
      case UNSURE -> Presentation.of(QuickFixBundle.message("add.exception.to.throws.text", unhandled.size()))
        .withFixAllOption(this);
      case YES -> Presentation.of(QuickFixBundle.message("add.exception.to.throws.hierarchy"));
      case NO -> Presentation.of(QuickFixBundle.message("add.exception.to.throws.only.this"));
    };
  }
@Override
  protected @Nullable Presentation getPresentation(@NotNull ActionContext context, @NotNull PsiElement element)