CompletionProposalCollector collector = new CompletionProposalCollector(project);
ICompilationUnit unit = FieldAssistUtils.getTemporaryCompilationUnit(project);
contents = contents.substring(0, position);
String source = "package " + contents;
FieldAssistUtils.setContentsToCU(unit, source);
unit.codeComplete(source.length(), collector, DefaultWorkingCopyOwner.PRIMARY);
IJavaCompletionProposal[] proposals = collector.getJavaCompletionProposals();
List<IContentProposal> result = new ArrayList<IContentProposal>();
for(int j=0;j<proposals.length;j++){
if(proposals[j].getImage()!=null){