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);
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

實作

適用於