System.Web.Configuration.OutputCacheProfile Class

Configures the output cache profile that can be used by the application pages. This class cannot be inherited.

See Also: OutputCacheProfile Members

Syntax

public sealed class OutputCacheProfile : System.Configuration.ConfigurationElement

Remarks

The System.Web.Configuration.OutputCacheProfile class provides a way to programmatically access and modify the add element of the outputCacheProfiles section in the caching section of a configuration file.

The System.Web.Configuration.OutputCacheProfile object centralizes frequently used configuration settings such as dependencies, cache location, and cache expiration time, eliminating the need to specify them on every page.

The System.Web.Configuration.OutputCacheProfile can be applied to a page using the CacheProfile attribute of the @ OutputCache directive.

Note:

The @ OutputCache directive can override all the settings contained by an System.Web.Configuration.OutputCacheProfile object except for the OutputCacheProfile.Enabled attribute. This is to enable or disable the System.Web.Configuration.OutputCacheProfile without having to modify the directives in all the pages that might have overridden it.

The System.Web.Caching.CacheDependency class monitors the dependencies so that when any cached item changes, the cached item will be automatically removed.

Requirements

Namespace: System.Web.Configuration
Assembly: System.Web (in System.Web.dll)
Assembly Versions: 2.0.0.0
Since: .NET 2.0