MemoryCache.TryGetValue(Object, Object) 方法

定義

取得與此索引鍵建立關聯的項目 (如有)。

public:
 virtual bool TryGetValue(System::Object ^ key, [Runtime::InteropServices::Out] System::Object ^ % result);
public bool TryGetValue (object key, out object result);
public bool TryGetValue (object key, out object? result);
abstract member TryGetValue : obj * obj -> bool
override this.TryGetValue : obj * obj -> bool
Public Function TryGetValue (key As Object, ByRef result As Object) As Boolean

參數

key
Object

識別所要求項目的物件。

result
Object

傳回

如果找到索引鍵,則為 true

實作

適用於