DistributedCacheExtensions.Set(IDistributedCache, String, Byte[]) Méthode
Définition
Important
Certaines informations portent sur la préversion du produit qui est susceptible d’être en grande partie modifiée avant sa publication. Microsoft exclut toute garantie, expresse ou implicite, concernant les informations fournies ici.
Définit une séquence d’octets dans le cache spécifié avec la clé spécifiée.
public:
[System::Runtime::CompilerServices::Extension]
static void Set(Microsoft::Extensions::Caching::Distributed::IDistributedCache ^ cache, System::String ^ key, cli::array <System::Byte> ^ value);
public static void Set(this Microsoft.Extensions.Caching.Distributed.IDistributedCache cache, string key, byte[] value);
static member Set : Microsoft.Extensions.Caching.Distributed.IDistributedCache * string * byte[] -> unit
<Extension()>
Public Sub Set (cache As IDistributedCache, key As String, value As Byte())
Paramètres
- cache
- IDistributedCache
Cache dans lequel stocker les données.
- key
- String
Clé dans laquelle stocker les données.
- value
- Byte[]
Données à stocker dans le cache.
Exceptions
key ou value a la valeur Null.