LRUCache<TKey,TValue> 建構函式
定義
重要
部分資訊涉及發行前產品,在發行之前可能會有大幅修改。 Microsoft 對此處提供的資訊,不做任何明確或隱含的瑕疵擔保。
多載
| LRUCache<TKey,TValue>(Int32) |
根據快取中的位置數目限制,建構 LRU 快取的新實例。 |
| LRUCache<TKey,TValue>(Int32, Int32, Func<TValue,Int32>) |
根據位置數目和記憶體大小限制,建構具有限制的 LRU 快取新實例。 |
LRUCache<TKey,TValue>(Int32)
根據快取中的位置數目限制,建構 LRU 快取的新實例。
public LRUCache (int entryLimit);
new MonoTouch.Dialog.Utilities.LRUCache<'Key, 'Value (requires 'Value : null and 'Value :> IDisposable)> : int -> MonoTouch.Dialog.Utilities.LRUCache<'Key, 'Value (requires 'Value : null and 'Value :> IDisposable)>
參數
- entryLimit
- Int32
LRU 快取上的專案數目上限。
適用於
LRUCache<TKey,TValue>(Int32, Int32, Func<TValue,Int32>)
根據位置數目和記憶體大小限制,建構具有限制的 LRU 快取新實例。
public LRUCache (int entryLimit, int sizeLimit, Func<TValue,int> slotSizer);
new MonoTouch.Dialog.Utilities.LRUCache<'Key, 'Value (requires 'Value : null and 'Value :> IDisposable)> : int * int * Func<'Value, int (requires 'Value : null and 'Value :> IDisposable)> -> MonoTouch.Dialog.Utilities.LRUCache<'Key, 'Value (requires 'Value : null and 'Value :> IDisposable)>
參數
- entryLimit
- Int32
LRU 快取上的專案數目上限。
- sizeLimit
- Int32
要保留在記憶體中的位元組數量上限。