Class CustomValuesSortCondition
Sort condition that orders cell values according to a custom list sequence, placing matching items first.
Inheritance
Inherited Members
Namespace: Telerik.Windows.Documents.Spreadsheet.Model.Sorting
Assembly: Telerik.Windows.Documents.Spreadsheet.dll
Syntax
public sealed class CustomValuesSortCondition : OrderedSortConditionBase<ICellValue>, ISortCondition, ITranslatable, ICopyable<ISortCondition>
Constructors
CustomValuesSortCondition(Int32, String[], SortOrder)
Initializes a new instance of the CustomValuesSortCondition class with a custom list defining the sort order.
Declaration
public CustomValuesSortCondition(int relativeIndex, string[] customList, SortOrder sortOrder)
Parameters
|
System.Int32
relativeIndex
Gets the index of the row or column that is key for sorting relative to the sorted range. |
|
System.String[]
customList
The custom list. |
|
SortOrder
sortOrder
The sort order. |
Properties
Comparer
Gets the comparer that ranks values by their position in the custom list.
Declaration
public override IComparer<SortValue> Comparer { get; }
Property Value
|
System.Collections.Generic.IComparer<SortValue>
The comparer used for sorting. |
Overrides
CustomList
Gets the ordered array of strings defining the custom sort sequence.
Declaration
public string[] CustomList { get; }
Property Value
|
System.String[]
The custom list. |
PropertyDefinition
Gets the cell value property definition used for custom list comparison.
Declaration
protected override IPropertyDefinition<ICellValue> PropertyDefinition { get; }
Property Value
|
IPropertyDefinition<ICellValue>
The property definition of the property which is used for sorting. |
Overrides
Methods
Equals(Object)
Determines whether the specified object is a CustomValuesSortCondition with the same custom list and settings.
Declaration
public override bool Equals(object obj)
Parameters
|
System.Object
obj
The object to compare with the current object. |
Returns
|
System.Boolean
true if the specified System.Object is equal to the current System.Object; otherwise, false. |
Overrides
GetHashCode()
Computes a hash code combining the base sort condition hash and the custom list content.
Declaration
public override int GetHashCode()
Returns
|
System.Int32
A hash code for the current System.Object. |