HttpCachePolicyWrapper Class
TOC
Collapse the table of content
Expand the table of content

HttpCachePolicyWrapper Class

.NET Framework (current version)
 

Encapsulates the HTTP intrinsic object that contains methods for setting cache-specific HTTP headers and for controlling the ASP.NET page output cache.

Namespace:   System.Web
Assembly:  System.Web (in System.Web.dll)

System.Object
  System.Web.HttpCachePolicyBase
    System.Web.HttpCachePolicyWrapper

public class HttpCachePolicyWrapper : HttpCachePolicyBase

NameDescription
System_CAPS_pubmethodHttpCachePolicyWrapper(HttpCachePolicy)

Initializes a new instance of the HttpCachePolicyWrapper class.

NameDescription
System_CAPS_pubpropertyVaryByContentEncodings

Gets the list of Content-Encoding headers that will be used to vary the output cache.(Overrides HttpCachePolicyBase.VaryByContentEncodings.)

System_CAPS_pubpropertyVaryByHeaders

Gets the list of all HTTP headers that will be used to vary cache output.(Overrides HttpCachePolicyBase.VaryByHeaders.)

System_CAPS_pubpropertyVaryByParams

Gets the list of parameters received by an HTTP GET or HTTP POST that affect caching.(Overrides HttpCachePolicyBase.VaryByParams.)

NameDescription
System_CAPS_pubmethodAddValidationCallback(HttpCacheValidateHandler, Object)

Registers a validation callback for the current response.(Overrides HttpCachePolicyBase.AddValidationCallback(HttpCacheValidateHandler, Object).)

System_CAPS_pubmethodAppendCacheExtension(String)

Appends the specified text to the Cache-Control HTTP header.(Overrides HttpCachePolicyBase.AppendCacheExtension(String).)

System_CAPS_pubmethodEquals(Object)

Determines whether the specified object is equal to the current object.(Inherited from Object.)

System_CAPS_protmethodFinalize()

Allows an object to try to free resources and perform other cleanup operations before it is reclaimed by garbage collection.(Inherited from Object.)

System_CAPS_pubmethodGetHashCode()

Serves as the default hash function. (Inherited from Object.)

System_CAPS_pubmethodGetType()

Gets the Type of the current instance.(Inherited from Object.)

System_CAPS_protmethodMemberwiseClone()

Creates a shallow copy of the current Object.(Inherited from Object.)

System_CAPS_pubmethodSetAllowResponseInBrowserHistory(Boolean)

Makes the response available in the browser history cache, regardless of the HttpCacheability setting made on the server.(Overrides HttpCachePolicyBase.SetAllowResponseInBrowserHistory(Boolean).)

System_CAPS_pubmethodSetCacheability(HttpCacheability)

Sets the Cache-Control header to the specified HttpCacheability value.(Overrides HttpCachePolicyBase.SetCacheability(HttpCacheability).)

System_CAPS_pubmethodSetCacheability(HttpCacheability, String)

Sets the Cache-Control header to the specified HttpCacheability value and appends an extension to the directive.(Overrides HttpCachePolicyBase.SetCacheability(HttpCacheability, String).)

System_CAPS_pubmethodSetETag(String)

Sets the ETag HTTP header to the specified string.(Overrides HttpCachePolicyBase.SetETag(String).)

System_CAPS_pubmethodSetETagFromFileDependencies()

Sets the ETag HTTP header based on the time stamps of the handler's file dependencies.(Overrides HttpCachePolicyBase.SetETagFromFileDependencies().)

System_CAPS_pubmethodSetExpires(DateTime)

Sets the Expires HTTP header to an absolute date and time.(Overrides HttpCachePolicyBase.SetExpires(DateTime).)

System_CAPS_pubmethodSetLastModified(DateTime)

Sets the Last-Modified HTTP header to the specified date and time.(Overrides HttpCachePolicyBase.SetLastModified(DateTime).)

System_CAPS_pubmethodSetLastModifiedFromFileDependencies()

Sets the Last-Modified HTTP header based on the time stamps of the handler's file dependencies.(Overrides HttpCachePolicyBase.SetLastModifiedFromFileDependencies().)

System_CAPS_pubmethodSetMaxAge(TimeSpan)

Sets the Cache-Control: max-age HTTP header to the specified time span.(Overrides HttpCachePolicyBase.SetMaxAge(TimeSpan).)

System_CAPS_pubmethodSetNoServerCaching()

Stops all origin-server caching for the current response.(Overrides HttpCachePolicyBase.SetNoServerCaching().)

System_CAPS_pubmethodSetNoStore()

Sets the Cache-Control: no-store HTTP header.(Overrides HttpCachePolicyBase.SetNoStore().)

System_CAPS_pubmethodSetNoTransforms()

Sets the Cache-Control: no-transform HTTP header.(Overrides HttpCachePolicyBase.SetNoTransforms().)

System_CAPS_pubmethodSetOmitVaryStar(Boolean)

Specifies whether the response contains the vary:* header when varying by parameters.(Overrides HttpCachePolicyBase.SetOmitVaryStar(Boolean).)

System_CAPS_pubmethodSetProxyMaxAge(TimeSpan)

Sets the Cache-Control: s-maxage HTTP header to the specified time span.(Overrides HttpCachePolicyBase.SetProxyMaxAge(TimeSpan).)

System_CAPS_pubmethodSetRevalidation(HttpCacheRevalidation)

Sets the Cache-Control HTTP header to either the must-revalidate or the proxy-revalidate directives, based on the specified enumeration value.(Overrides HttpCachePolicyBase.SetRevalidation(HttpCacheRevalidation).)

System_CAPS_pubmethodSetSlidingExpiration(Boolean)

Sets cache expiration to absolute or sliding.(Overrides HttpCachePolicyBase.SetSlidingExpiration(Boolean).)

System_CAPS_pubmethodSetValidUntilExpires(Boolean)

Specifies whether the ASP.NET cache should ignore HTTP Cache-Control headers sent by the client that invalidate the cache.(Overrides HttpCachePolicyBase.SetValidUntilExpires(Boolean).)

System_CAPS_pubmethodSetVaryByCustom(String)

Specifies a text string to vary cached output responses by.(Overrides HttpCachePolicyBase.SetVaryByCustom(String).)

System_CAPS_pubmethodToString()

Returns a string that represents the current object.(Inherited from Object.)

The HttpCachePolicyWrapper class derives from the HttpCachePolicyBase class and serves as a wrapper for the HttpCachePolicy class. This class exposes the functionality of the HttpCachePolicy class while also exposing the HttpCachePolicyBase type. The HttpCachePolicyBase class enables you to replace the original implementation of the HttpCachePolicy class in your application with a custom implementation, such as when you perform unit testing outside the ASP.NET pipeline.

.NET Framework
Available since 3.5

Any public static (Shared in Visual Basic) members of this type are thread safe. Any instance members are not guaranteed to be thread safe.

Return to top
Show:
© 2016 Microsoft