TypeNameCollector typeNameCollector = new TypeNameCollector(javaProject, requireTypeInProject);
//System.out.println("BindingReflectionUtils.findElementType: start " + System.currentTimeMillis());
BindingReflectionUtils.findMatchingElementClassNames(elementTypeName, SearchPattern.R_EXACT_MATCH, typeNameCollector, progressMonitor);
//System.out.println("BindingReflectionUtils.findElementType: " + (System.currentTimeMillis() - a));
if (typeNameCollector.isExactMatch()) {
String matchingElementClassName = typeNameCollector.firstTypeName();
type = typeNameCollector.getTypeForClassName(matchingElementClassName);
}
else if (!typeNameCollector.isEmpty()) {
// there was more than one matching class! crap!
String matchingElementClassName = typeNameCollector.firstTypeName();