HttpCachePolicyBase.SetCacheability 方法
定義
重要
部分資訊涉及發行前產品,在發行之前可能會有大幅修改。 Microsoft 對此處提供的資訊,不做任何明確或隱含的瑕疵擔保。
在衍生類別中覆寫時,將 Cache-Control
標頭設定為其中一個 HttpCacheability 值。
多載
SetCacheability(HttpCacheability) |
在衍生類別中覆寫時,將 |
SetCacheability(HttpCacheability, String) |
在衍生類別中覆寫時,將 |
SetCacheability(HttpCacheability)
在衍生類別中覆寫時,將 Cache-Control
標頭設定為指定的 HttpCacheability 值。
public:
virtual void SetCacheability(System::Web::HttpCacheability cacheability);
public virtual void SetCacheability (System.Web.HttpCacheability cacheability);
abstract member SetCacheability : System.Web.HttpCacheability -> unit
override this.SetCacheability : System.Web.HttpCacheability -> unit
Public Overridable Sub SetCacheability (cacheability As HttpCacheability)
參數
- cacheability
- HttpCacheability
要設定標頭的目標 HttpCacheability 列舉值。
例外狀況
適用於
SetCacheability(HttpCacheability, String)
在衍生類別中覆寫時,將 Cache-Control
標頭設定為指定的 HttpCacheability 值,並將擴充功能附加至指示詞。
public:
virtual void SetCacheability(System::Web::HttpCacheability cacheability, System::String ^ field);
public virtual void SetCacheability (System.Web.HttpCacheability cacheability, string field);
abstract member SetCacheability : System.Web.HttpCacheability * string -> unit
override this.SetCacheability : System.Web.HttpCacheability * string -> unit
Public Overridable Sub SetCacheability (cacheability As HttpCacheability, field As String)
參數
- cacheability
- HttpCacheability
要設定標頭的目標 HttpCacheability 列舉值。
- field
- String
要加入標頭中的快取控制項擴充功能。