feat(infinite-query): add all the features of query in infinite query
Separated common logic of both `InfiniteQuery` and `Query` in a base class `BaseQuery` resulting in `InfiniteQuery` inheriting already having implemented features of `Query`
This commit is contained in:
@@ -1,7 +1,7 @@
|
||||
import 'package:fl_query/src/query_bowl.dart';
|
||||
import 'package:flutter/widgets.dart';
|
||||
|
||||
abstract class BaseOperation<Data> extends ChangeNotifier {
|
||||
abstract class BaseOperation<Data, Error> extends ChangeNotifier {
|
||||
/// The number of times the query should refetch in the time of error
|
||||
/// before giving up
|
||||
final int retries;
|
||||
@@ -13,7 +13,7 @@ abstract class BaseOperation<Data> extends ChangeNotifier {
|
||||
|
||||
// all properties
|
||||
Data? data;
|
||||
dynamic error;
|
||||
Error? error;
|
||||
|
||||
/// total count of how many times the query retried to get a successful
|
||||
/// result
|
||||
|
||||
Reference in New Issue
Block a user