} if (bestOffset == Integer.MAX_VALUE) {
if (bestOffset == Integer.MAX_VALUE) { return invocationLocation; } for (int i= 0; i < allPositions.size(); i++) { Position pos= (Position) allPositions.get(i); if (isInside(bestOffset, pos.offset, pos.offset + pos.length)) { resultingAnnotations.add(allAnnotations.get(i)); } } return bestOffset; } else { while (iter.hasNext()) { Annotation annot= (Annotation) iter.next(); if (JavaCorrectionProcessor.isQuickFixableType(annot)) { Position pos= model.getPosition(annot); if (pos != null && isInside(invocationLocation, pos.offset, pos.offset + pos.length)) { resultingAnnotations.add(annot); } } }
	public static int collectQuickFixableAnnotations(ITextEditor editor, int invocationLocation, boolean goToClosest, ArrayList resultingAnnotations) throws BadLocationException {		IRegion lineInfo= editor.getDocumentProvider().getDocument(editor.getEditorInput()).getLineInformationOfOffset(invocationLocation);		int rangeStart= lineInfo.getOffset();		int rangeEnd= rangeStart + lineInfo.getLength();		IAnnotationModel model= JavaUI.getDocumentProvider().getAnnotationModel(editor.getEditorInput());				int bestOffset= Integer.MAX_VALUE;		Iterator iter= model.getAnnotationIterator();		while (iter.hasNext()) {			Annotation annot= (Annotation) iter.next();			if (JavaCorrectionProcessor.isQuickFixableType(annot)) {				Position pos= model.getPosition(annot);				if (pos != null && isInside(pos.offset, rangeStart, rangeEnd)) { // inside our range?					bestOffset= processAnnotation(annot, pos, invocationLocation, bestOffset, goToClosest, resultingAnnotations);				}			}		}		if (bestOffset == Integer.MAX_VALUE) {			return invocationLocation;		}				return bestOffset;	}