public class SortHelper extends RangeHelperBase
Modifier and Type | Class and Description |
---|---|
static class |
SortHelper.SortKey |
Modifier and Type | Field and Description |
---|---|
static int |
SORT_HEADER_NO |
static int |
SORT_HEADER_YES |
range, sheet
Constructor and Description |
---|
SortHelper(SRange range) |
Modifier and Type | Method and Description |
---|---|
void |
sort(SRange key1,
boolean descending1,
SRange.SortDataOption dataOption1,
SRange key2,
boolean descending2,
SRange.SortDataOption dataOption2,
SRange key3,
boolean descending3,
SRange.SortDataOption dataOption3,
int header,
boolean matchCase,
boolean sortByRows)
Major procedure for sorting a selected range:
record merged region, sort, unmerge merged regions, restore merged region
|
getColumn, getFormatEngine, getFormattedText, getFormulaEngine, getLastColumn, getLastRow, getRow, isBlank, isWholeColumn, isWholeRow, isWholeSheet
public static final int SORT_HEADER_NO
public static final int SORT_HEADER_YES
public SortHelper(SRange range)
public void sort(SRange key1, boolean descending1, SRange.SortDataOption dataOption1, SRange key2, boolean descending2, SRange.SortDataOption dataOption2, SRange key3, boolean descending3, SRange.SortDataOption dataOption3, int header, boolean matchCase, boolean sortByRows)
key1
- the range that contains first keys to sortdescending1
- the order to sort first keydataOption1
- BookHelper.SORT_TEXT_AS_NUMBERS, BookHelper.SORT_NORMAL_DEFAULTkey2
- descending2
- dataOption2
- key3
- descending3
- dataOption3
- header
- matchCase
- sortByRows
- sort by keys in rows, true means "left to right", and false means "top to bottom"Copyright © 2020. All rights reserved.