public bool Contains(TK key) { if (_range.IsWithin(key)) { var cursor = _underlying.FindUnique(key, _underlying.RootCursor); if (cursor.IsNotEnd) { return(Equals(key, cursor.Key)); } } return(false); }
public bool Contains(TK key) { return(_range.IsWithin(key) && _underlying.ContainsKey(key)); }
/// <summary> /// Determines whether the <see cref="T:System.Collections.Generic.ICollection`1" /> contains a specific value. /// </summary> /// <param name="item">The object to locate in the <see cref="T:System.Collections.Generic.ICollection`1" />.</param> /// <returns> /// true if <paramref name="item" /> is found in the <see cref="T:System.Collections.Generic.ICollection`1" />; otherwise, false. /// </returns> public bool Contains(KeyValuePair <TK, TV> item) { return(_range.IsWithin(item.Key) && _parent.Contains(item)); }