@Override
  protected @NotNull ModCommand perform(@NotNull ActionContext context, @NotNull PsiElement element) {
    final Set<PsiClassType> exceptions = new HashSet<>();
    final PsiMethod targetMethod = collectExceptions(exceptions, element);
    if (targetMethod == null) return ModCommand.nop();
    ModCommand command = addExceptionsToThrowsList(context.project(), targetMethod, exceptions, myProcessHierarchy);
    if (command == null) {
      return ModCommand.chooseAction(QuickFixBundle.message("add.exception.to.throws.header", exceptions.size()),
                                     new AddExceptionToThrowsFix(element, ThreeState.YES),
                                     new AddExceptionToThrowsFix(element, ThreeState.NO));
    }

    return command;
  }
@Override
  protected @NotNull ModCommand perform(@NotNull ActionContext context, @NotNull PsiElement element)