configureLazyPagination method
void
configureLazyPagination({})
inherited
Configures page metadata without retaining or splitting all root rows.
Implementation
void configureLazyPagination({
required int totalRowCount,
required int pageSize,
required int currentPage,
}) {
if (totalRowCount < 0) {
throw ArgumentError.value(totalRowCount, 'totalRowCount', 'Cannot be negative');
}
if (pageSize <= 0) {
throw ArgumentError.value(pageSize, 'pageSize', 'Must be greater than zero');
}
_pageItemCount = max(1, (totalRowCount / pageSize).ceil());
currentPageNotifier.value = currentPage.clamp(0, _pageItemCount - 1);
treeRowNodesPagesNotifier.value = null;
}