Global default policy and kill-switch for all ISpect redaction.
Every redaction path routes through this gate: network interceptors (Dio/HTTP/WS), database tracing, BLoC/Riverpod observers, the trace pipeline, navigation route arguments, and every export path (JSON, text, Markdown, file share, clipboard, cURL).
Configure service once to apply application-specific masking across core
diagnostics and supported integrations. Explicit integration services stay
local overrides. Setting enabled to false disables content masking
everywhere at once, overriding per-integration enableRedaction flags.
Defaults to true. Because captured diagnostics can contain sensitive data,
disabling redaction is a deliberate opt-out - leave it on unless a build
genuinely needs raw payloads.
ISpectRedaction.configure(
service: RedactionService(
additionalSensitiveKeys: {'tenant_secret'},
),
);
// Deliberate local-debugging opt-out:
ISpect.run(() => runApp(MyApp()), redactionEnabled: false);
Properties
- hashCode → int
-
The hash code for this object.
no setterinherited
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
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
Static Properties
- enabled ↔ bool
-
getter/setter pair
- service → RedactionService
-
The default redaction policy used by every ISpect integration.
no setter
Static Methods
-
configure(
{bool? enabled, RedactionService? service}) → void - Updates the process-isolate redaction defaults.
-
reset(
) → void - Restores enabled redaction with a fresh default service.
-
resolveService(
{RedactionService? service, Iterable< String> ? sensitiveKeys}) → RedactionService - Resolves a redaction service using the shared precedence contract.