FetchStrategyBuilder constructor
const
FetchStrategyBuilder({
- Duration timeout = const Duration(seconds: 30),
- Duration totalFetchTimeout = const Duration(minutes: 1),
- int maxAttempts = 5,
- Duration initialPauseBetweenRetries = const Duration(seconds: 1),
- num exponentialBackoffMultiplier = 2,
- TransientHttpStatusCodePredicate transientHttpStatusCodePredicate = defaultTransientHttpStatusCodePredicate,
Creates a fetch strategy builder.
All parameters must be non-null.
Implementation
const FetchStrategyBuilder({
this.timeout = const Duration(seconds: 30),
this.totalFetchTimeout = const Duration(minutes: 1),
this.maxAttempts = 5,
this.initialPauseBetweenRetries = const Duration(seconds: 1),
this.exponentialBackoffMultiplier = 2,
this.transientHttpStatusCodePredicate =
defaultTransientHttpStatusCodePredicate,
});