Class UriSessionStartCriterionBase<T>

Base class fro Uri criterion

Inheritance
System.Object
EPiServer.Personalization.VisitorGroups.CriterionBase<T>
UriSessionStartCriterionBase<T>
Implements
EPiServer.Personalization.VisitorGroups.ICriterion
EPiServer.Personalization.VisitorGroups.IGeneratesAdministrativeInterface
Inherited Members
EPiServer.Personalization.VisitorGroups.CriterionBase<T>.Initialize(EPiServer.Personalization.VisitorGroups.VisitorGroupCriterion)
EPiServer.Personalization.VisitorGroups.CriterionBase<T>.Model
EPiServer.Personalization.VisitorGroups.CriterionBase<T>.EPiServer.Personalization.VisitorGroups.IGeneratesAdministrativeInterface.ModelType
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.Personalization.VisitorGroups.Criteria
Assembly: EPiServer.dll
Version: 8.11.0
Syntax
public abstract class UriSessionStartCriterionBase<T> : CriterionBase<T>, ICriterion, IGeneratesAdministrativeInterface where T : class, ICriterionModel, new()
Type Parameters
Name Description
T

Constructors

UriSessionStartCriterionBase()

Declaration
protected UriSessionStartCriterionBase()

Properties

SessionKey

Gets or sets the session key.

Declaration
public abstract string SessionKey { get; }
Property Value
Type Description
System.String

The session key.

Methods

GetSession(HttpContextBase)

Gets the session.

Declaration
protected object GetSession(HttpContextBase httpContext)
Parameters
Type Name Description
System.Web.HttpContextBase httpContext

The HTTP context.

Returns
Type Description
System.Object

GetUri(HttpContextBase)

Gets the URI.

Declaration
protected abstract Uri GetUri(HttpContextBase httpContext)
Parameters
Type Name Description
System.Web.HttpContextBase httpContext

The HTTP context.

Returns
Type Description
System.Uri

IsMatch(IPrincipal, HttpContextBase)

Determines whether the specified principal is mathced the hostname referer criteria.

Declaration
public override bool IsMatch(IPrincipal principal, HttpContextBase httpContext)
Parameters
Type Name Description
System.Security.Principal.IPrincipal principal

The principal.

System.Web.HttpContextBase httpContext

The HTTP context.

Returns
Type Description
System.Boolean

true if the specified principal is match; otherwise, false.

Overrides
EPiServer.Personalization.VisitorGroups.CriterionBase<T>.IsMatch(System.Security.Principal.IPrincipal, System.Web.HttpContextBase)

IsMatch(Uri)

Determines whether the specified URI is match.

Declaration
protected abstract bool IsMatch(Uri uri)
Parameters
Type Name Description
System.Uri uri

The URI.

Returns
Type Description
System.Boolean

true if the specified URI is match; otherwise, false.

Subscribe(ICriterionEvents)

Called when a criteria instance is initialized. Starts listenen on session start

Declaration
public override void Subscribe(ICriterionEvents criterionEvents)
Parameters
Type Name Description
EPiServer.Personalization.VisitorGroups.ICriterionEvents criterionEvents

The criterion notifier.

Overrides
EPiServer.Personalization.VisitorGroups.CriterionBase<T>.Subscribe(EPiServer.Personalization.VisitorGroups.ICriterionEvents)
Remarks

Any event subscribed to in this method should be unsubscribed in method Unsubscribe. The reason for this is that otherwise there will be "dangling" event handlers.

Unsubscribe(ICriterionEvents)

Called when a criteria is unloaded, for example because it seetings has been updated. Unsubscribes the session start handler

Declaration
public override void Unsubscribe(ICriterionEvents criterionEvents)
Parameters
Type Name Description
EPiServer.Personalization.VisitorGroups.ICriterionEvents criterionEvents
Overrides
EPiServer.Personalization.VisitorGroups.CriterionBase<T>.Unsubscribe(EPiServer.Personalization.VisitorGroups.ICriterionEvents)

Implements

EPiServer.Personalization.VisitorGroups.ICriterion
EPiServer.Personalization.VisitorGroups.IGeneratesAdministrativeInterface

Extension Methods