using System; using System.Threading.Tasks; using System.Collections.Generic; namespace YiSha.Cache.Interface { public interface ICache { bool SetCache(string key, T value, DateTime? expireTime = null); T GetCache(string key); bool RemoveCache(string key); #region Hash int SetHashFieldCache(string key, string fieldKey, T fieldValue); int SetHashFieldCache(string key, Dictionary dict); T GetHashFieldCache(string key, string fieldKey); Dictionary GetHashFieldCache(string key, Dictionary dict); Dictionary GetHashCache(string key); List GetHashToListCache(string key); bool RemoveHashFieldCache(string key, string fieldKey); Dictionary RemoveHashFieldCache(string key, Dictionary dict); #endregion } }