using Furion.JsonSerialization; using YBEE.EQM.Core; namespace YBEE.EQM.Application { public interface ICacheService { Task AddCacheKey(string cacheKey); Task DelByPatternAsync(string key); Task DelCacheKey(string cacheKey); bool Exists(string cacheKey); Task> GetAllCacheKeys(); Task GetAsync(string cacheKey); Task> GetDataScope(int userId); Task> GetPermission(int userId); Task RemovePermission(int userId); Task GetStringAsync(string cacheKey); Task RemoveAsync(string key); Task SetAsync(string cacheKey, object value); Task SetDataScope(int userId, List dataScopes); Task SetPermission(int userId, List permissions); Task SetStringAsync(string cacheKey, string value); Task> GetMenu(int userId); Task SetMenu(int userId, List menus); /// /// 获取角色数据范围权限缓存 /// /// /// Task> GetRoleDataScope(int userId); /// /// 删除角色数据范围权限缓存 /// /// /// Task RemoveRoleDataScope(int userId); /// /// 缓存角色数据范围权限 /// /// /// /// Task SetRoleDataScope(int userId, List roles); } }