SliverGroupedListView<T, E> constructor
const
SliverGroupedListView<T, E> ({
- Key? key,
- required List<
T> elements, - required E groupBy(
- T element
- int groupComparator(
- E value1,
- E value2
- Widget groupSeparatorBuilder(
- E value
- Widget groupHeaderBuilder(
- T element
- Widget itemBuilder(
- BuildContext context,
- T element
- Widget indexedItemBuilder(
- BuildContext context,
- T element,
- int index
- int itemComparator(
- T element1,
- T element2
- GroupedListOrder order = GroupedListOrder.ASC,
- bool sort = true,
- Widget separator = const SizedBox.shrink(),
Creates a SliverGroupedListView
Implementation
const SliverGroupedListView({
super.key,
required this.elements,
required this.groupBy,
this.groupComparator,
this.groupSeparatorBuilder,
this.groupHeaderBuilder,
this.itemBuilder,
this.indexedItemBuilder,
this.itemComparator,
this.order = GroupedListOrder.ASC,
this.sort = true,
this.separator = const SizedBox.shrink(),
this.footer,
}) : assert(itemBuilder != null || indexedItemBuilder != null),
assert(groupSeparatorBuilder != null || groupHeaderBuilder != null);