copyWith method
PagedState<PageKeyType, ItemType>
copyWith({
- List<
ItemType> ? records, - dynamic error,
- dynamic nextPageKey = undefined,
Implementation
PagedState<PageKeyType, ItemType> copyWith(
{List<ItemType>? records,
dynamic error,
dynamic nextPageKey = undefined}) {
return PagedState<PageKeyType, ItemType>(
records: records ?? this.records,
error: error ?? this.error,
nextPageKey: nextPageKey == undefined
? this.nextPageKey
: nextPageKey as PageKeyType?);
}