DistributedCacheExtensions.GetString(IDistributedCache, String) Método

Definição

Obtém uma cadeia de caracteres do cache especificado com a chave especificada.

public:
[System::Runtime::CompilerServices::Extension]
 static System::String ^ GetString(Microsoft::Extensions::Caching::Distributed::IDistributedCache ^ cache, System::String ^ key);
public static string GetString (this Microsoft.Extensions.Caching.Distributed.IDistributedCache cache, string key);
public static string? GetString (this Microsoft.Extensions.Caching.Distributed.IDistributedCache cache, string key);
static member GetString : Microsoft.Extensions.Caching.Distributed.IDistributedCache * string -> string
<Extension()>
Public Function GetString (cache As IDistributedCache, key As String) As String

Parâmetros

cache
IDistributedCache

O cache no qual armazenar os dados.

key
String

A chave para a qual obter os dados armazenados.

Retornos

O valor da cadeia de caracteres da chave de cache armazenada.

Aplica-se a