Show / Hide Table of Contents

Class TypedArchiveRowComparer<RowType>

Comparer class used to compare two ArchiveRow objects according to the given orderby criteria. This class handles comparisons by both OrderByValue and DisplayValue, type harmonization and conversions, and multiple ascending/descending orderby criteria.

If you have a set of archive row iterators, you can use the ArchiveRowIteratorComparer class to sort the iterators according to their .Current rows

Inheritance
Object
TypedArchiveRowComparer<RowType>
ArchiveRowComparer
Implements
IComparer<RowType>
Inherited Members
Object.ToString()
Object.Equals(Object)
Object.Equals(Object, Object)
Object.ReferenceEquals(Object, Object)
Object.GetHashCode()
Object.GetType()
Object.MemberwiseClone()
Namespace: SuperOffice.CRM.ArchiveLists
Assembly: SoCore.dll
Syntax
public class TypedArchiveRowComparer<RowType> : IComparer<RowType> where RowType : ArchiveRow
Type Parameters
Name Description
RowType

Constructors

TypedArchiveRowComparer(ArchiveOrderByInfo[])

Construct the comparer, and set the orderby criteria.

Declaration
public TypedArchiveRowComparer(params ArchiveOrderByInfo[] orderByInfo)
Parameters
Type Name Description
ArchiveOrderByInfo[] orderByInfo

Set of ordering criteria. null is not acceptable. An empty array will cause all elements to be considered equal to another; the final result then depends on the behaviour of the sorting algorithm. If the algorithm is 'stable', no change in order will happen; otherwise the final ordering is undefined.

Methods

Compare(RowType, RowType)

Compare two ArchiveRow elements according to the orderby criteria set

Declaration
public int Compare(RowType xRow, RowType yRow)
Parameters
Type Name Description
RowType xRow

Left-hand row

RowType yRow

Right-hand row

Returns
Type Description
Int32

-1, 0 or 1 according to actual row data order

Implements

System.Collections.Generic.IComparer<T>

Extension Methods

EnumUtil.MapEnums<From, To>(From)
Converters.MapEnums<From, To>(From)
© SuperOffice. All rights reserved.
SuperOffice |  Community |  Release Notes |  Privacy |  Site feedback |  Search Docs |  About Docs |  Contribute |  Back to top