bool IDictionary <Type, Type> .TryGetValue(Type key, out Type value) { List <Type> list; bool result = _extensionMap.TryGetValue(key, out list); if (result) { value = CollectionUtils.FirstElement(list); return(value != null); } value = null; return(false); }
private static XmlElement GetFirstElementWithTagName(XmlNode xmlElement, string tagName) { return((XmlElement)CollectionUtils.FirstElement(xmlElement.SelectNodes(tagName))); }