//创建缓存依赖项 CacheDependency dep = new CacheDependency(fileName); //创建缓存 HttpContext.Current.Cache.Insert(key, obj, dep);
获取CacheDependency 的方法
if (string.IsNullOrEmpty(key)) { return null; } return HttpContext.Current.Cache.Get(key);