C# 程序缓存
下面的代码行将做什么 这将设置缓存时间C# 程序缓存,c#,caching,C#,Caching,下面的代码行将做什么 这将设置缓存时间 Response.Cache.SetExpires(DateTime.Now.AddSeconds(60)); 这有什么用 Response.Cache.SetCacheability(HttpCacheability.NoCache); 这是干什么用的?。。第一行代码集缓存为什么这行代码需要true Response.Cache.SetValidUntilExpires(true); 提前谢谢 DivyaHttpCacheability.NoCac
Response.Cache.SetExpires(DateTime.Now.AddSeconds(60));
这有什么用
Response.Cache.SetCacheability(HttpCacheability.NoCache);
这是干什么用的?。。第一行代码集缓存为什么这行代码需要true
Response.Cache.SetValidUntilExpires(true);
提前谢谢
DivyaHttpCacheability.NoCache将响应头设置为无缓存,如下所述
响应.Cache.SetCacheability(HttpCacheability.NoCache)代码> “设置缓存控制HTTP标头。缓存控制HTTP标头控制如何在网络上缓存文档。”- --
Response.Cache.SetValidUntilExpires(true)代码>
“指定ASP.NET缓存是否应忽略使缓存无效的客户端发送的HTTP缓存控制头。”-