copyWith method
Implementation
PaginationState<T> copyWith({
List<T>? items,
int? currentPage,
int? pageSize,
int? totalItems,
bool? hasMore,
bool? isLoading,
Object? error,
}) {
return PaginationState<T>(
items: items ?? this.items,
currentPage: currentPage ?? this.currentPage,
pageSize: pageSize ?? this.pageSize,
totalItems: totalItems ?? this.totalItems,
hasMore: hasMore ?? this.hasMore,
isLoading: isLoading ?? this.isLoading,
error: error ?? this.error,
);
}