NativeDataTable.builder constructor

NativeDataTable.builder({
  1. required List<DataColumn> columns,
  2. int rowsPerPage = PaginatedDataTable.defaultRowsPerPage,
  3. required int itemCount,
  4. required DataRowBuilder itemBuilder,
  5. int? totalItems,
  6. Widget? header,
  7. ValueChanged<int?>? onRowsPerPageChanged,
  8. ValueChanged<bool?>? onSelectAll,
  9. bool? sortAscending,
  10. bool showSelect = true,
  11. bool showSort = true,
  12. int? sortColumnIndex,
  13. IndexedWidgetBuilder? mobileItemBuilder,
  14. Size tabletBreakpoint = _kTabletBreakpoint,
  15. List<Widget>? actions,
  16. List<Widget>? selectedActions,
  17. int firstRowIndex = 0,
  18. RefreshCallback? onRefresh,
  19. int mobileFetchNextRows = 100,
  20. VoidCallback? handlePrevious,
  21. VoidCallback? handleNext,
  22. bool rowCountApproximate = false,
  23. Widget? noItems,
  24. Widget? mobileIsLoading,
  25. List<Widget>? mobileSlivers,
  26. bool alwaysShowDataTable = false,
})

Implementation

NativeDataTable.builder({
  required this.columns,
  this.rowsPerPage = PaginatedDataTable.defaultRowsPerPage,
  required int itemCount,
  required DataRowBuilder itemBuilder,
  this.totalItems,
  this.header,
  this.onRowsPerPageChanged,
  this.onSelectAll,
  this.sortAscending,
  this.showSelect = true,
  this.showSort = true,
  this.sortColumnIndex,
  this.mobileItemBuilder,
  this.tabletBreakpoint = _kTabletBreakpoint,
  this.actions,
  this.selectedActions,
  this.firstRowIndex = 0,
  this.onRefresh,
  this.mobileFetchNextRows = 100,
  this.handlePrevious,
  this.handleNext,
  this.rowCountApproximate = false,
  this.noItems,
  this.mobileIsLoading,
  this.mobileSlivers,
  this.alwaysShowDataTable = false,
}) : rows = _buildRows(itemCount, itemBuilder);