LibreOffice LibreOffice 25.2 SDK API Reference

Public Member Functions | List of all members
XSortableGridData Interface Reference

allows to sort the data represented by a XGridDataModel More...

`import"XSortableGridData.idl";`

Inheritance diagram for XSortableGridData:

## Public Member Functions
void | sortByColumn ([in] long ColumnIndex, [in] boolean SortAscending) raises ( ::com::sun::star::lang::IndexOutOfBoundsException )
| sorts the rows represented by the model by a given column's data. More...
void | removeColumnSort ()
| removes any possibly present sorting of the grid data More...
::com::sun::star::beans::Pair< long, boolean > | getCurrentSortOrder ()
| returns the current sort order. More...

## Detailed Description

allows to sort the data represented by a XGridDataModel

## Member Function Documentation

## ◆ getCurrentSortOrder()

::com::sun::star::beans::Pair< long, boolean > getCurrentSortOrder | ( |  | ) |

returns the current sort order.

Returns
  a structure describing the current sort order. com::sun::star::beans::Pair::First denotes the column by which the data is sorted, or -1 if the data is currently unsorted. com::sun::star::beans::Pair::Second is `TRUE` if the data is sorted ascending, `FALSE` otherwise.

## ◆ removeColumnSort()

void removeColumnSort | ( |  | ) |

removes any possibly present sorting of the grid data

## ◆ sortByColumn()

void sortByColumn | ( | [in] long | ColumnIndex,
|  | [in] boolean | SortAscending
| ) |  |
raises | ( | ::com::sun::star::lang::IndexOutOfBoundsException
| ) |  |

sorts the rows represented by the model by a given column's data.

Parameters

  ColumnIndex | the index of the column whose data should be used as sort key
  SortAscending | is `TRUE` if the data should be sorted ascending, `FALSE` otherwise.

Exceptions

  com::sun::star::lang::IndexOutOfBoundsException | if `ColumnIndex` does not denote a valid column.

The documentation for this interface was generated from the following file:

- com/sun/star/awt/grid/XSortableGridData.idl