Class PageFilterBase
Base class for filters implementing IPageFilter
Namespace: EPiServer.Filters
Assembly: EPiServer.Cms.AspNetCore.dll
Version: 12.0.3Syntax
public abstract class PageFilterBase : Object, IPageFilter, IContentFilterConstructors
PageFilterBase()
Initializes a new instance of the PageFilterBase class.
Declaration
protected PageFilterBase()Properties
RequestTime
Gets or sets the request time used for filters dependent on the request time.
Declaration
public virtual Nullable<DateTime> RequestTime { get; set; }Property Value
| Type | Description | 
|---|---|
| System.Nullable<System.DateTime> | The request time. | 
Methods
Filter(PageDataCollection)
Filters the specified pages.
Declaration
public virtual void Filter(PageDataCollection pages)Parameters
| Type | Name | Description | 
|---|---|---|
| PageDataCollection | pages | The pages that should be filtered. | 
Filter(IList<IContent>)
Filters the specified pages.
Declaration
public virtual void Filter(IList<IContent> contents)Parameters
| Type | Name | Description | 
|---|---|---|
| System.Collections.Generic.IList<IContent> | contents | The contents. | 
Filter(Object, ContentFilterEventArgs)
Eventhandler that applies the filter for a PageDataCollection.
Declaration
public void Filter(object sender, ContentFilterEventArgs e)Parameters
| Type | Name | Description | 
|---|---|---|
| System.Object | sender | The class/instance that initiated the Filter event. | 
| ContentFilterEventArgs | e | The ContentFilterEventArgs arguments containing the event data. | 
Filter(Object, FilterEventArgs)
Event handler that applies the filter on a PageDataCollection.
Declaration
public virtual void Filter(object sender, FilterEventArgs e)Parameters
| Type | Name | Description | 
|---|---|---|
| System.Object | sender | The class/instance that initiated the Filter event. | 
| FilterEventArgs | e | The FilterEventArgs arguments containing the event data. | 
ShouldFilter(IContent)
Determines whether the content should be filtered.
Declaration
public abstract bool ShouldFilter(IContent content)Parameters
| Type | Name | Description | 
|---|---|---|
| IContent | content | 
Returns
| Type | Description | 
|---|---|
| System.Boolean | 
 | 
ShouldFilter(PageData)
Determines whether the page should be filtered.
Declaration
public abstract bool ShouldFilter(PageData page)Parameters
| Type | Name | Description | 
|---|---|---|
| PageData | page | The page to be checked. | 
Returns
| Type | Description | 
|---|---|
| System.Boolean | 
 | 
