WsDiagnosticsSink class abstract interface

Provider-agnostic sink for WebSocket diagnostics.

Any WebSocket client binds to ISpect by pushing events through this contract; the orchestration (WsDiagnostics) owns redaction, filtering, correlation, and emission. Metrics and connection state are optional — clients that cannot report them omit the arguments.

Implementers

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

newConnection() → void
Resets the correlation id, starting a new connection session.
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
onError(Object error, StackTrace stackTrace, {String? url}) → void
Records a connection-level error not tied to a single frame.
onReceived(Object data, {String? url, Map<String, Object?>? metrics}) → void
Records an inbound frame. url and metrics are optional context.
onSent(Object data, {String? url, Map<String, Object?>? metrics}) → void
Records an outbound frame. url and metrics are optional context.
onStateChanged(WsConnectionState state, {String? url, Object? raw}) → void
Records a connection-state transition. raw is the client's own state object, retained as a stringified hint when present.
toString() String
A string representation of this object.
inherited

Operators

operator ==(Object other) bool
The equality operator.
inherited