MemoryDistributedCache Sınıf

Tanım

kullanarak IMemoryCacheuygularIDistributedCache.

public ref class MemoryDistributedCache : Microsoft::Extensions::Caching::Distributed::IDistributedCache
public class MemoryDistributedCache : Microsoft.Extensions.Caching.Distributed.IDistributedCache
type MemoryDistributedCache = class
    interface IDistributedCache
Public Class MemoryDistributedCache
Implements IDistributedCache
Devralma
MemoryDistributedCache
Uygulamalar

Oluşturucular

Name Description
MemoryDistributedCache(IOptions<MemoryDistributedCacheOptions>, ILoggerFactory)

Yeni bir MemoryDistributedCache örneği oluşturur.

MemoryDistributedCache(IOptions<MemoryDistributedCacheOptions>)

Yeni bir MemoryDistributedCache örneği oluşturur.

Yöntemler

Name Description
Get(String)

bayt dizisi olarak bir anahtarla ilişkilendirilmiş belirtilen öğeyi IMemoryCache alır.

GetAsync(String, CancellationToken)

Zaman uyumsuz olarak bayt dizisi olarak bir anahtarla ilişkilendirilmiş belirtilen öğeyi IMemoryCache alır.

Refresh(String)

öğesinden bir anahtarla ilişkilendirilmiş belirtilen öğeyi IMemoryCacheyeniler.

RefreshAsync(String, CancellationToken)

öğesinden IMemoryCachebir anahtarla ilişkili belirtilen öğeyi zaman uyumsuz olarak yeniler.

Remove(String)

bir anahtarla ilişkilendirilmiş belirtilen öğeyi IMemoryCacheöğesinden kaldırır.

RemoveAsync(String, CancellationToken)

bir anahtarla ilişkili belirtilen öğeyi öğesinden IMemoryCachezaman uyumsuz olarak kaldırır.

Set(String, Byte[], DistributedCacheEntryOptions)

içindeki bir anahtarla IMemoryCache ilişkilendirilmiş belirtilen öğeyi bayt dizisi olarak ayarlar.

SetAsync(String, Byte[], DistributedCacheEntryOptions, CancellationToken)

bir bayt dizisindeki bir anahtarla ilişkili belirtilen öğeyi IMemoryCache zaman uyumsuz olarak ayarlar.

Uzantı Metotları

Name Description
GetString(IDistributedCache, String)

Belirtilen önbellekten belirtilen anahtarla bir dize alır.

GetStringAsync(IDistributedCache, String, CancellationToken)

Belirtilen önbellekten belirtilen anahtarla zaman uyumsuz olarak bir dize alır.

Set(IDistributedCache, String, Byte[])

Belirtilen önbellekte belirtilen anahtarla bir bayt dizisi ayarlar.

SetAsync(IDistributedCache, String, Byte[], CancellationToken)

Belirtilen önbellekte belirtilen anahtarla zaman uyumsuz olarak bir bayt dizisi ayarlar.

SetString(IDistributedCache, String, String, DistributedCacheEntryOptions)

Belirtilen önbellekte belirtilen anahtarla bir dize ayarlar.

SetString(IDistributedCache, String, String)

Belirtilen önbellekte belirtilen anahtarla bir dize ayarlar.

SetStringAsync(IDistributedCache, String, String, CancellationToken)

Belirtilen önbellekte belirtilen anahtarla zaman uyumsuz olarak bir dize ayarlar.

SetStringAsync(IDistributedCache, String, String, DistributedCacheEntryOptions, CancellationToken)

Belirtilen önbellekte belirtilen anahtarla zaman uyumsuz olarak bir dize ayarlar.

Şunlara uygulanır