Bug 121627 [[code generation wizards] AddGetterSetterAction object should provide getter method for dialog result.
I have a scenario where multiple document edits are desired as part of a quick fix implementation: 1. Invoking AddGetterSetterAction.run() to offer the creation of Getter/Setter methods 2. If the above is not canceled, change the access modifier for a public field to private. Unfortunately, the AddGetterSetterAction has no private field which tracks the dialog result (e.g. Window.OK) ... As a work-around, the user can use edit-undo to back off the access modifier change after a cancel operation...
org.eclipse.jdt.ui/ui/org/eclipse/jdt/ui/actions/OverrideMethodsAction.java
CompilationUnit astRoot= dialog.getCompilationUnit();
			final ITypeBinding typeBinding= ASTNodes.getTypeBinding(astRoot, type);
			int insertPos= dialog.getInsertOffset();
			
			AddUnimplementedMethodsOperation operation= (AddUnimplementedMethodsOperation) createRunnable(astRoot, typeBinding, methodToOverride, insertPos, dialog.getGenerateComment());
			IRunnableContext context= JavaPlugin.getActiveWorkbenchWindow();
			if (context == null)
				context= new BusyIndicatorRunnableContext();
			PlatformUI.getWorkbench().getProgressService().runInUI(context, new WorkbenchRunnableAdapter(operation, operation.getSchedulingRule()), operation.getSchedulingRule());
			final String[] created= operation.getCreatedMethods();
			if (created == null || created.length == 0)
				MessageDialog.openInformation(shell, getDialogTitle(), ActionMessages.OverrideMethodsAction_error_nothing_found); 
		} catch (InvocationTargetException exception) {
			ExceptionHandler.handle(exception, shell, getDialogTitle(), null);
		} catch (InterruptedException exception) {
			
		} finally {
			if (target != null)
				target.endCompoundChange();
		}
	}
	/**
	 * Returns a runnable that creates the method stubs for overridden methods.
	 * 
	 * @param astRoot the AST of the compilation unit to work on. The AST must have been created from a {@link ICompilationUnit}, that
	 * means {@link ASTParser#setSource(ICompilationUnit)} was used.
	 * @param type the binding of the type to add the new methods to. The type binding must correspond to a type declaration in the AST.
	 * @param methodToOverride the bindings of methods to override or <code>null</code> to implement all unimplemented, abstract methods from super types.
	 * @param insertPos a hint for a location in the source where to insert the new methods or <code>-1</code> to use the default behavior.
	 * @param createComments if set, comments will be added to the new methods.