Bug 50460 [templates] Template toarray not proposed
I200401130800 return new DelegatingValidationStateChange(to<code assist>); observe: poposals don't contain an entry for the toarray templete
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/text/template/contentassist/TemplateEngine.java
} catch (BadLocationException e) {}
		}
		
		CompilationUnitContext context= ((CompilationUnitContextType) fContextType).createContext(document, completionPosition, selection.y, compilationUnit);
		context.setVariable("selection", selectedText); 
		int start= context.getStart();
		int end= context.getEnd();
		IRegion region= new Region(start, end - start);
		Template[] templates= Templates.getInstance().getTemplates();
		if (selection.y == 0) {
			for (int i= 0; i != templates.length; i++)
				if (context.canEvaluate(templates[i]))
					fProposals.add(new TemplateProposal(templates[i], context, region, JavaPluginImages.get(JavaPluginImages.IMG_OBJS_TEMPLATE)));
		} else {
			if (context.getKey().length() == 0)
				context.setForceEvaluation(true);
			boolean multipleLinesSelected= areMultipleLinesSelected(viewer);
				
			for (int i= 0; i != templates.length; i++) {
				Template template= templates[i];				
				if (context.canEvaluate(template) &&
					template.getContextTypeName().equals(context.getContextType().getName()) &&				
					(!multipleLinesSelected && template.getPattern().indexOf($_WORD_SELECTION) != -1 || (multipleLinesSelected && template.getPattern().indexOf($_LINE_SELECTION) != -1)))
				{
					fProposals.add(new TemplateProposal(templates[i], context, region, JavaPluginImages.get(JavaPluginImages.IMG_OBJS_TEMPLATE)));
				}
			}
		}
	}