if (type != null) {
if (type != null && _elementNameToTypeCache != null) {
	public static IType findElementType(IJavaProject _javaProject, String _elementTypeName, boolean _requireTypeInProject, Map _elementNameToTypeCache) throws JavaModelException {		// Search the current project for the given element type name		IType type;		if (_elementNameToTypeCache != null) {			type = (IType) _elementNameToTypeCache.get(_elementTypeName);		} else {			type = null;		}		if (type == null) {			TypeNameCollector typeNameCollector = new TypeNameCollector(_javaProject, _requireTypeInProject);			WodBindingUtils.findMatchingElementClassNames(_elementTypeName, SearchPattern.R_EXACT_MATCH, typeNameCollector);			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();				type = typeNameCollector.getTypeForClassName(matchingElementClassName);			} else {				type = null;			}			if (type != null) {				_elementNameToTypeCache.put(_elementTypeName, type);			}		}		return type;	}