Try our conversational search powered by Generative AI!

Class CachedUrlHandler

Handler for cached URL rewrite requests.

Inherited Members
System.Object.ToString()
System.Object.Equals(System.Object)
System.Object.Equals(System.Object, System.Object)
System.Object.ReferenceEquals(System.Object, System.Object)
System.Object.GetHashCode()
System.Object.GetType()
System.Object.MemberwiseClone()
Namespace: EPiServer.Web
Assembly: EPiServer.Cms.AspNet.dll
Version: 11.20.7
Syntax
public abstract class CachedUrlHandler
Remarks

A class deriving from CachedUrlHandler can implement the IHandleUrlForRewrite interface. Usually you will have some overlap in functionality between the RewriteFromCachedData method and the TryHandleUrl method on IHandleUrlForRewrite and thus implemeting that interface on the handler class usually makes sense.

NOTE! If you do implement the interface on a CachedUrlHandler instance you should conceptually (and usually in practice) treat the IHandleUrlForRewrite and CachedUrlHandler as distinct and disjunct objects.

Constructors

CachedUrlHandler()

Declaration
protected CachedUrlHandler()

Methods

RewriteFromCachedData(UrlRewriteContext, ref Object)

Rewrites the URL from cached data.

Declaration
public abstract bool RewriteFromCachedData(UrlRewriteContext context, ref object internalObject)
Parameters
Type Name Description
UrlRewriteContext context

The context.

System.Object internalObject

The internal object.

Returns
Type Description
System.Boolean

True if the URL was rewritten, false otherwise.

Remarks

You may optionally return an internal representation of the page in internalObject. This will usually be a PageReference, but you should always check the type and not assume that it is a PageReference since internalObject may contain anything depending on the actual CachedUrlHandler implementation.

Extension Methods