PerformanceOptions class
Performance configuration options for a query.
Controls performance-related features like isolate usage, retry behavior, and performance tracking for individual queries.
Constructors
- PerformanceOptions({bool enableMetrics = true, int? fetchTimeoutMs, bool autoIsolate = false, int? isolateThreshold, bool enableHotCache = true, int maxRetries = 3, Duration initialRetryDelay = const Duration(seconds: 1), double retryBackoffMultiplier = 2.0, bool enableDataTransform = false, FutureOr dataTransformer(dynamic data)?})
-
const
Properties
- autoIsolate → bool
-
Enable automatic isolate usage based on threshold
final
- dataTransformer → FutureOr Function(dynamic data)?
-
Custom data transformer executed when enableDataTransform is true
final
- enableDataTransform → bool
-
Enable custom data transformation hook
final
- enableHotCache → bool
-
Enable hot cache for this query
final
- enableMetrics → bool
-
Enable detailed performance tracking for this query
final
- fetchTimeoutMs → int?
-
Maximum fetch time before warning (milliseconds)
final
- hashCode → int
-
The hash code for this object.
no setterinherited
- initialRetryDelay → Duration
-
Initial retry delay
final
- isolateThreshold → int?
-
Custom isolate threshold for this query (overrides global)
final
- maxRetries → int
-
Maximum number of fetch retries
final
- retryBackoffMultiplier → double
-
Backoff multiplier for retries
final
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
Methods
-
copyWith(
{bool? enableMetrics, int? fetchTimeoutMs, bool? autoIsolate, int? isolateThreshold, bool? enableHotCache, int? maxRetries, Duration? initialRetryDelay, double? retryBackoffMultiplier, bool? enableDataTransform, FutureOr dataTransformer(dynamic data)?}) → PerformanceOptions - Create a copy with some fields changed
-
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
toString(
) → String -
A string representation of this object.
override
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited