ReadOnlyMetadataCollection<T>.TryGetValue(String, Boolean, T) 方法
定义
重要
一些信息与预发行产品相关,相应产品在发行之前可能会进行重大修改。 对于此处提供的信息,Microsoft 不作任何明示或暗示的担保。
使用指定的标识从此集合中检索项。
public:
virtual bool TryGetValue(System::String ^ identity, bool ignoreCase, [Runtime::InteropServices::Out] T % item);
public virtual bool TryGetValue(string identity, bool ignoreCase, out T item);
abstract member TryGetValue : string * bool * 'T -> bool
override this.TryGetValue : string * bool * 'T -> bool
Public Overridable Function TryGetValue (identity As String, ignoreCase As Boolean, ByRef item As T) As Boolean
参数
- identity
- String
要搜索的项的标识。
- ignoreCase
- Boolean
true 执行不区分大小写的搜索;否则,为 false.
- item
- T
此方法返回时,此输出参数包含集合中的项。 如果没有匹配的项,则此输出参数包含 null。
返回
true 如果存在与搜索条件匹配的项,则为否则,为 false.