Esempio n. 1
0
 /// <summary>
 /// Determines whether this instance contains the object.
 /// </summary>
 /// <param name="cache">The cache.</param>
 /// <param name="key">The key.</param>
 /// <param name="values">The values.</param>
 /// <returns>
 ///   <c>true</c> if [contains] [the specified key]; otherwise, <c>false</c>.
 /// </returns>
 public static bool Contains(this IDistributedCache cache, DistributedCacheRegistration key, params object[] values) => cache.Contains(key.GetName(values));
Esempio n. 2
0
 /// <summary>
 /// Removes the specified key.
 /// </summary>
 /// <param name="cache">The cache.</param>
 /// <param name="key">The key.</param>
 /// <param name="values">The values.</param>
 public static void Remove(this IDistributedCache cache, DistributedCacheRegistration key, params object[] values) => cache.Remove(key.GetName(values));