OutputCacheSettingsSection.OutputCacheProfiles Свойство
Определение
Важно!
Некоторые сведения относятся к предварительной версии продукта, в которую до выпуска могут быть внесены существенные изменения. Майкрософт не предоставляет никаких гарантий, явных или подразумеваемых, относительно приведенных здесь сведений.
OutputCacheProfileCollectionВозвращает .
public:
property System::Web::Configuration::OutputCacheProfileCollection ^ OutputCacheProfiles { System::Web::Configuration::OutputCacheProfileCollection ^ get(); };
[System.Configuration.ConfigurationProperty("outputCacheProfiles")]
public System.Web.Configuration.OutputCacheProfileCollection OutputCacheProfiles { get; }
[<System.Configuration.ConfigurationProperty("outputCacheProfiles")>]
member this.OutputCacheProfiles : System.Web.Configuration.OutputCacheProfileCollection
Public ReadOnly Property OutputCacheProfiles As OutputCacheProfileCollection
Значение свойства
OutputCacheProfile ОбъектOutputCacheProfileCollection.
- Атрибуты
Примеры
В следующем примере кода показано, как использовать OutputCacheProfiles свойство.
// Get the current OutputCacheProfiles property value.
OutputCacheProfileCollection outputCacheProfilesValue =
outputCacheSettings.OutputCacheProfiles;
' Get the current OutputCacheProfiles property value.
Dim outputCacheProfilesValue _
As OutputCacheProfileCollection = _
outputCacheSettings.OutputCacheProfiles
Комментарии
Свойство OutputCacheProfiles позволяет программным способом получить доступ к элементу outputCacheProfiles в файле конфигурации. Свойство можно использовать OutputCacheProfiles для программного outputCacheProfiles изменения элемента.
В outputCacheProfiles разделе содержатся OutputCacheProfile объекты, представляющие параметры кэша выходных данных, которые могут использоваться страницами в приложении. Эти параметры можно применить к странице, задав CacheProfile атрибут директивы @OutputCache . Примените профиль для управления атрибутами кэширования, такими как зависимости, расположение кэша и время истечения срока действия кэша.
Директива @OutputCache может переопределить все параметры, содержащиеся в свойстве OutputCacheProfileEnabled . Это позволяет включить или отключить OutputCacheProfile директивы на всех страницах, которые могли переопределить его.