sockets/media_socket_errors library
Enums
- MediaSocketConnectPhase
- Where a media socket connection attempt stopped.
Constants
-
mediaConnectionRejectionReasons
→ const List<
String> -
Reasons a media node sends with
connection-rejected { reason, stage }(media admission v2) just before it closes a refused handshake.
Functions
-
currentOnlineState(
) → bool? -
navigator.onLineon web; null elsewhere (unknown). -
describeMediaSocketError(
Object? error, {String fallback = 'Unable to connect. Check your credentials and try again.'}) → String -
User-facing text for any connection error;
fallbackfor errors that are not MediaSocketConnectException. -
isRetryableMediaSocketError(
Object? error) → bool - False only for rejections that cannot succeed on retry with the same credentials.
-
normalizeRejectionReason(
Object? reason) → String -
Maps any reason from the server onto a known one (unknown values become
rejected-before-connection-success).
Exceptions / Errors
- MediaSocketConnectException
-
Thrown by
connectSocketwhen the media socket cannot be used.