NativeDataTable.builder constructor
NativeDataTable.builder({
- required List<
DataColumn> columns, - int rowsPerPage = PaginatedDataTable.defaultRowsPerPage,
- required int itemCount,
- required DataRowBuilder itemBuilder,
- int? totalItems,
- Widget? header,
- ValueChanged<
int?> ? onRowsPerPageChanged, - ValueChanged<
bool?> ? onSelectAll, - bool? sortAscending,
- bool showSelect = true,
- bool showSort = true,
- int? sortColumnIndex,
- IndexedWidgetBuilder? mobileItemBuilder,
- Size tabletBreakpoint = _kTabletBreakpoint,
- List<
Widget> ? actions, - List<
Widget> ? selectedActions, - int firstRowIndex = 0,
- RefreshCallback? onRefresh,
- int mobileFetchNextRows = 100,
- VoidCallback? handlePrevious,
- VoidCallback? handleNext,
- bool rowCountApproximate = false,
- Widget? noItems,
- Widget? mobileIsLoading,
- List<
Widget> ? mobileSlivers, - 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);