BlowePaginationListView<B extends BlowePaginationBloc<BlowePaginationModel<T> , P> , T, P, G> constructor
const
BlowePaginationListView<B extends BlowePaginationBloc<BlowePaginationModel<T> , P> , T, P, G> ({
- required BlowePaginationListViewItemBuilder<
T> itemBuilder, - required BloweFetchParamsProvider<
P> paramsProvider, - Widget? emptyWidget,
- Widget? startWidget,
- Widget? endWidget,
- EdgeInsetsGeometry? padding,
- BloweItemFilter<
T> ? filter, - BloweItemGrouper<
T, G> ? groupBy, - BloweGroupHeaderBuilder<
T, G> ? groupHeaderBuilder, - BlowePaginationErrorBuilder? errorBuilder,
- bool onRefreshEnabled = true,
- B? bloc,
- bool shrinkWrap = false,
- Key? key,
Creates an instance of BlowePaginationListView.
- itemBuilder: The builder function to create list items.
- paramsProvider: A function that provides parameters for the BloweFetch event.
- emptyWidget: A widget to display when the list is empty.
- padding: Optional padding for the list view.
- filter: Optional function to filter items in the list.
- groupBy: Optional function to group items in the list.
- groupHeaderBuilder: Optional builder function to create group headers.
- errorBuilder: Optional builder function to create a custom error widget.
- onRefreshEnabled: Indicates if the refresh functionality is enabled.
- bloc: The bloc to use for the list view.
Implementation
const BlowePaginationListView({
required this.itemBuilder,
required this.paramsProvider,
this.emptyWidget,
this.startWidget,
this.endWidget,
this.padding,
this.filter,
this.groupBy,
this.groupHeaderBuilder,
this.errorBuilder,
this.onRefreshEnabled = true,
this.bloc,
this.shrinkWrap = false,
super.key,
}) : assert(
groupBy == null || groupHeaderBuilder != null,
'groupBy and groupHeaderBuilder must be provided together',
);