public static void HashGetTest(IRedisCache redisCache) { var res = redisCache.HGet <string>("TestHashID", "0"); Debug.WriteLine("HashGet:" + res); Debug.WriteLine("==================================="); var resList = redisCache.HGet <string>("TestHashID", new string[] { "1", "200", "6", "78", "133", "300", "100", "56", "99" }); foreach (var item in resList) { Debug.WriteLine(item); } }
/// <summary> /// /// </summary> /// <param name="cache"></param> /// <param name="key"></param> /// <param name="field"></param> /// <returns></returns> public static (string output, bool IsOk) HGet(this IRedisCache cache, string key, string field) { return(cache.HGet <string>(key, field)); }