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/AddUnimplementedConstructorsAction.java
private static class AddUnimplementedConstructorsContentProvider implements ITreeContentProvider {
		private static final Object[] EMPTY= new Object[0];
		private IMethodBinding[] fMethodsList= new IMethodBinding[0];
		private final CompilationUnit fUnit;
	
		public AddUnimplementedConstructorsContentProvider(IType type) throws JavaModelException {
			RefactoringASTParser parser= new RefactoringASTParser(AST.JLS3);
			fUnit= parser.parse(type.getCompilationUnit(), true);
			AbstractTypeDeclaration declaration= (AbstractTypeDeclaration) ASTNodes.getParent(NodeFinder.perform(fUnit, type.getNameRange()), AbstractTypeDeclaration.class);
			if (declaration != null) {
				ITypeBinding binding= declaration.resolveBinding();
				if (binding != null)
					fMethodsList= StubUtility2.getVisibleConstructors(binding, true, false);
			}
		}
		public CompilationUnit getCompilationUnit() {
			return fUnit;
		}
		/*
		 * @see IContentProvider#dispose()
		 */
		public void dispose() {
		}
		/*
		 * @see ITreeContentProvider#getChildren(Object)
		 */
		public Object[] getChildren(Object parentElement) {
			return EMPTY;
		}
		/*