ErrorHandlerConfig class
Configuration for error handling behavior.
Constructors
-
ErrorHandlerConfig({bool enableLogging = true, bool enableReporting = false, Duration maxRecoveryTime = const Duration(seconds: 30), bool useCircuitBreaker = true, void errorReporter(StateException error, Map<
String, dynamic> context)?, void logger(String message, {Map<String, dynamic> ? context, String? level})?}) -
const
Properties
- enableLogging → bool
-
Whether to enable error logging.
final
- enableReporting → bool
-
Whether to enable error reporting to external services.
final
-
errorReporter
→ void Function(StateException error, Map<
String, dynamic> context)? -
Custom error reporter function.
final
- hashCode → int
-
The hash code for this object.
no setterinherited
-
logger
→ void Function(String message, {Map<
String, dynamic> ? context, String? level})? -
Custom logger function.
final
- maxRecoveryTime → Duration
-
Maximum time to spend on recovery attempts.
final
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
- useCircuitBreaker → bool
-
Whether to use circuit breaker for cascading failure prevention.
final
Methods
-
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
toString(
) → String -
A string representation of this object.
inherited
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited