Bug 44204 Promote individual methods to interface.
Methods should be able to be promoted to an implemented interface. IE interface SomeThing { public DoDad getDoDad(); } class MyThing implements Something { private DoDad doDad=new DoDad(); public DoDad getDoDad() { return doDad; } public void setDoDad(DoDad dad) { this.doDad=dad; } ^^^^^^^^ } Ctrl-1 on the ^'d should produce 'Declare in interface 'Something''. if more than on interface, multiple options should be given, much like what import does. This enhancement would save time copying, pasting and trimming. Regards, Andy
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/text/correction/QuickAssistProcessor.java
if (childProperty == IfStatement.THEN_STATEMENT_PROPERTY) {
			label = CorrectionMessages.getString("QuickAssistProcessor.replacethenwithblock.description");
		} else if (childProperty == IfStatement.ELSE_STATEMENT_PROPERTY) {
			label = CorrectionMessages.getString("QuickAssistProcessor.replaceelsewithblock.description");
		} else {
			label = CorrectionMessages.getString("QuickAssistProcessor.replacebodywithblock.description");
		}
		
		Image image= JavaPluginImages.get(JavaPluginImages.IMG_CORRECTION_CHANGE);
		LinkedCorrectionProposal proposal= new LinkedCorrectionProposal(label, context.getCompilationUnit(), rewrite, 10, image);
		proposal.setEndPosition(rewrite.track(child));
		resultingCollections.add(proposal);
		return true;
	}
	
	private boolean getInvertEqualsProposal(IInvocationContext context, ASTNode node, Collection resultingCollections) {
		ASTNode parent= node.getParent();
		if (!(parent instanceof MethodInvocation)) {
			return false;
		}
		MethodInvocation method= (MethodInvocation) parent;
		if (!"equals".equals(method.getName().getIdentifier())) { 
			return false;
		}
		List arguments= method.arguments();
		if (arguments.size() != 1) { 
			return false;
		}
		Expression right= (Expression) arguments.get(0);
		ITypeBinding binding = right.resolveTypeBinding();