ImmutableSortedDictionary<TKey,TValue>.IDictionary.Contains(Object) 方法

定义

确定不可变字典对象是否包含具有指定键的元素。Determines whether the immutable dictionary object contains an element with the specified key.

 virtual bool System.Collections.IDictionary.Contains(System::Object ^ key) = System::Collections::IDictionary::Contains;
bool IDictionary.Contains (object key);
abstract member System.Collections.IDictionary.Contains : obj -> bool
override this.System.Collections.IDictionary.Contains : obj -> bool
Function Contains (key As Object) As Boolean Implements IDictionary.Contains

参数

key
Object

要在字典对象中查找的键。The key to locate in the dictionary object.

返回

Boolean

如果字典包含具有该键的元素,则为 true;否则为 falsetrue if the dictionary contains an element with the key; otherwise, false.

实现

注解

此成员是显式接口成员的实现。This member is an explicit interface member implementation. 它只能在 ImmutableSortedDictionary<TKey,TValue> 实例被强制转换为 IDictionary 接口时使用。It can be used only when the ImmutableSortedDictionary<TKey,TValue> instance is cast to an IDictionary interface.

适用于