SystemWebCachingSectionGroup.Cache プロパティ

定義

構成に含まれる cache セクションを取得します。

public:
 property System::Web::Configuration::CacheSection ^ Cache { System::Web::Configuration::CacheSection ^ get(); };
[System.Configuration.ConfigurationProperty("cache")]
public System.Web.Configuration.CacheSection Cache { get; }
[<System.Configuration.ConfigurationProperty("cache")>]
member this.Cache : System.Web.Configuration.CacheSection
Public ReadOnly Property Cache As CacheSection

プロパティ値

CacheSection オブジェクトです。

属性

次のコード例は、既存の Web アプリケーションの構成ファイルから CacheSection オブジェクトを取得する方法を示しています。


 // Get the <cache> section.
 CacheSection cache =
     cachingSectionGroup.Cache;

 // Display one of its properties.
 msg = String.Format(
 "Cache disable expiration: {0}\n",
 cache.DisableExpiration);

 Console.Write(msg);
' Get the <cache> section.
Dim cache As CacheSection = _
cachingSectionGroup.Cache

' Display one of its properties.
msg = String.Format( _
"Cache disable expiration: {0}" + _
ControlChars.Lf, cache.DisableExpiration)

Console.Write(msg)

注釈

CacheSection オブジェクトは、構成ファイルの cache セクションを参照します。 CacheSection クラスを使用して、cache セクションをプログラムで変更できます。

適用対象

こちらもご覧ください