C# Класс ZForge.Controls.XPTable.Sorting.SorterBase

Base class for the sorters used to sort the Cells contained in a TableModel
Показать файл Открыть проект

Открытые методы

Метод Описание
Sort ( ) : void

Starts sorting the Cells in the TableModel

SorterBase ( TableModel tableModel, int column, IComparer comparer, SortOrder sortOrder ) : System

Initializes a new instance of the SorterBase class with the specified TableModel, Column index, IComparer and SortOrder

Защищенные методы

Метод Описание
Compare ( Row row1, Row row2 ) : int

Compares two rows and returns a value indicating whether one is less than, equal to or greater than the other. Takes into account the sort order.

CompareRows ( Row row1, Row row2 ) : int

Compares two rows and returns a value indicating whether one is less than, equal to or greater than the other. Compares the given rows without considering parent/sub-rows.

CompareRows ( Row row1, Row row2, int column, IComparer comparer ) : int

Compares two rows and returns a value indicating whether one is less than, equal to or greater than the other. Compares the given rows without considering parent/sub-rows.

Set ( int a, Row row ) : void

Replaces the Row in the TableModel located at index a with the specified Row

Set ( int a, int b ) : void

Replaces the Row in the TableModel located at index a with the Row located at index b

Swap ( int a, int b ) : void

Swaps the Rows in the TableModel at the specified indexes

Описание методов

Compare() защищенный Метод

Compares two rows and returns a value indicating whether one is less than, equal to or greater than the other. Takes into account the sort order.
protected Compare ( Row row1, Row row2 ) : int
row1 ZForge.Controls.XPTable.Models.Row First row to compare
row2 ZForge.Controls.XPTable.Models.Row Second row to compare
Результат int

CompareRows() защищенный Метод

Compares two rows and returns a value indicating whether one is less than, equal to or greater than the other. Compares the given rows without considering parent/sub-rows.
protected CompareRows ( Row row1, Row row2 ) : int
row1 ZForge.Controls.XPTable.Models.Row
row2 ZForge.Controls.XPTable.Models.Row
Результат int

CompareRows() защищенный Метод

Compares two rows and returns a value indicating whether one is less than, equal to or greater than the other. Compares the given rows without considering parent/sub-rows.
protected CompareRows ( Row row1, Row row2, int column, IComparer comparer ) : int
row1 ZForge.Controls.XPTable.Models.Row
row2 ZForge.Controls.XPTable.Models.Row
column int
comparer IComparer
Результат int

Set() защищенный Метод

Replaces the Row in the TableModel located at index a with the specified Row
protected Set ( int a, Row row ) : void
a int The index of the Row that will be replaced
row ZForge.Controls.XPTable.Models.Row The Row that will be moved to index a
Результат void

Set() защищенный Метод

Replaces the Row in the TableModel located at index a with the Row located at index b
protected Set ( int a, int b ) : void
a int The index of the Row that will be replaced
b int The index of the Row that will be moved to index a
Результат void

Sort() публичный абстрактный Метод

Starts sorting the Cells in the TableModel
public abstract Sort ( ) : void
Результат void

SorterBase() публичный Метод

Initializes a new instance of the SorterBase class with the specified TableModel, Column index, IComparer and SortOrder
public SorterBase ( TableModel tableModel, int column, IComparer comparer, SortOrder sortOrder ) : System
tableModel ZForge.Controls.XPTable.Models.TableModel The TableModel that contains the data to be sorted
column int The index of the Column to be sorted
comparer IComparer The IComparer used to sort the Column's Cells
sortOrder SortOrder Specifies how the Column is to be sorted
Результат System

Swap() защищенный Метод

Swaps the Rows in the TableModel at the specified indexes
protected Swap ( int a, int b ) : void
a int The index of the first Row to be swapped
b int The index of the second Row to be swapped
Результат void