TListControllerPagination<T, K> extension

Extension providing pagination functionality for TListController.

Handles both client-side and server-side pagination with methods to:

  • Navigate between pages
  • Change items per page
  • Load more items (infinite scroll)
  • Refresh data
  • Handle search

Example:

// Navigate pages
controller.goToNextPage();
controller.goToFirstPage();

// Change page size
controller.handleItemsPerPageChange(25);

// Infinite scroll
controller.handleLoadMore();

// Search
controller.handleSearchChange('query');

// Get pagination info
print(controller.paginationInfo);
// "Showing 1 to 10 of 100 entries"
on

Properties

canGoToNextPage bool

Available on TListController<T, K>, provided by the TListControllerPagination extension

Whether there is a next page.
no setter
canGoToPreviousPage bool

Available on TListController<T, K>, provided by the TListControllerPagination extension

Whether there is a previous page.
no setter
computedItemsPerPage int

Available on TListController<T, K>, provided by the TListControllerPagination extension

The computed items per page (adjusted for last page).
no setter
hasMoreItems bool

Available on TListController<T, K>, provided by the TListControllerPagination extension

Whether there are more items to load.
no setter
isFirstPage bool

Available on TListController<T, K>, provided by the TListControllerPagination extension

Whether this is the first page.
no setter
isLastPage bool

Available on TListController<T, K>, provided by the TListControllerPagination extension

Whether this is the last page.
no setter
itemsPerPage int

Available on TListController<T, K>, provided by the TListControllerPagination extension

The number of items per page.
no setter
page int

Available on TListController<T, K>, provided by the TListControllerPagination extension

The current page number (1-indexed).
no setter
pageEndedAt int

Available on TListController<T, K>, provided by the TListControllerPagination extension

The ending index of the current page.
no setter
pageStartedAt int

Available on TListController<T, K>, provided by the TListControllerPagination extension

The starting index of the current page.
no setter
paginationInfo String

Available on TListController<T, K>, provided by the TListControllerPagination extension

Human-readable pagination information.
no setter
totalDisplayItems int

Available on TListController<T, K>, provided by the TListControllerPagination extension

The number of items currently displayed.
no setter
totalItems int

Available on TListController<T, K>, provided by the TListControllerPagination extension

The total number of items.
no setter
totalPages int

Available on TListController<T, K>, provided by the TListControllerPagination extension

The total number of pages.
no setter

Methods

computeItemsPerPageOptions(List<int> options) List<int>

Available on TListController<T, K>, provided by the TListControllerPagination extension

goToFirstPage() → void

Available on TListController<T, K>, provided by the TListControllerPagination extension

goToLastPage() → void

Available on TListController<T, K>, provided by the TListControllerPagination extension

goToNextPage() → void

Available on TListController<T, K>, provided by the TListControllerPagination extension

goToPreviousPage() → void

Available on TListController<T, K>, provided by the TListControllerPagination extension

handleItemsPerPageChange(int newItemsPerPage) → void

Available on TListController<T, K>, provided by the TListControllerPagination extension

handleLoadMore() → void

Available on TListController<T, K>, provided by the TListControllerPagination extension

handlePageChange(int newPage) → void

Available on TListController<T, K>, provided by the TListControllerPagination extension

handleRefresh() → void

Available on TListController<T, K>, provided by the TListControllerPagination extension

handleSearchChange(String search) → void

Available on TListController<T, K>, provided by the TListControllerPagination extension

handleSearchImmediate(String search) → void

Available on TListController<T, K>, provided by the TListControllerPagination extension