The datagrid allows to sort columns based on custom logic. For each column, you can provide different sorting criteria by overriding the following methods from DataGridSource,
- handleSort : This method will be called when you tap the column header and sorting is being applied. You can override this method to provide the entire logic for sorting for columns.
- compare : You can override this method to compare two objects and return the sorting order based on the criteria.
This application shows how to perform custom sorting for the columns based on the case-insensitive by overriding the compare
method.