Class FilterSort
A filter to sort a PageDataCollection using a predefined FilterSortOrder.
Inherited Members
Namespace: EPiServer.Filters
Assembly: EPiServer.dll
Version: 9.12.2Syntax
public class FilterSort : PageFilterBase, IPageFilter, IContentFilter
Constructors
FilterSort()
Initializes a new instance of the FilterSort class.
Declaration
public FilterSort()
FilterSort(FilterSortOrder)
Initializes a new instance of the FilterSort class.
Declaration
public FilterSort(FilterSortOrder sortOrder)
Parameters
Type | Name | Description |
---|---|---|
FilterSortOrder | sortOrder | The sort order. |
FilterSort(FilterSortOrder, CompareInfo)
Initializes a new instance of the FilterSort class.
Declaration
public FilterSort(FilterSortOrder sortOrder, CompareInfo comparer)
Parameters
Type | Name | Description |
---|---|---|
FilterSortOrder | sortOrder | The sort order. |
System.Globalization.CompareInfo | comparer | The System.Globalization.CompareInfo that is used for comparison. |
Properties
SortOrder
The sort order for the filter.
Declaration
public FilterSortOrder SortOrder { get; set; }
Property Value
Type | Description |
---|---|
FilterSortOrder |
Methods
Filter(PageDataCollection)
Sorts the specified pages.
Declaration
public override void Filter(PageDataCollection pages)
Parameters
Type | Name | Description |
---|---|---|
PageDataCollection | pages | The pages that should be sorted. |
Overrides
ShouldFilter(IContent)
If the content should be filtered.
Declaration
public override bool ShouldFilter(IContent content)
Parameters
Type | Name | Description |
---|---|---|
IContent | content |
Returns
Type | Description |
---|---|
System.Boolean | True if the filter will remove the page; otherwise false. |
Overrides
ShouldFilter(PageData)
If the page should be filtered.
Declaration
public override bool ShouldFilter(PageData page)
Parameters
Type | Name | Description |
---|---|---|
PageData | page | The page that you want to check. |
Returns
Type | Description |
---|---|
System.Boolean | True if the filter will remove the page; otherwise false. |
Overrides
Remarks
FilterSort does not support ShouldFilter method.
Sort(PageDataCollection)
Sorts a collection of pages
Declaration
public void Sort(PageDataCollection pages)
Parameters
Type | Name | Description |
---|---|---|
PageDataCollection | pages | The pages that should be sorted. |