WebRTCStreamController class
The stream's state for the whole page, so a view that remounts finds it as it was.
A view attaches while it shows the stream and detaches when it goes. The session outlives the last view for keepAlive, so a language or theme change keeps the picture; after that the next view opens a new session from the producers the client already knows, without waiting for an event that fired before it existed.
Constructors
- WebRTCStreamController(SignallingClient _client, {required int reconnectionTimeoutMs, String? producerId, Duration keepAlive = const Duration(seconds: 30), Duration retryAfter = const Duration(seconds: 3)})
Properties
- detail → String Function(dynamic l10n)?
-
The reason behind stage, localized at render time;
nullmeans the stage's default.no setter - hashCode → int
-
The hash code for this object.
no setterinherited
- keepAlive → Duration
-
How long a session stays open with no view attached.
final
- producerId → String?
-
Consume only this producer;
nulltakes the first one announced.final - reconnectionTimeoutMs → int
-
The signalling client's retry interval, for the message after a dropped connection.
final
- retryAfter → Duration
-
How long after a failed session the next one is tried.
final
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
- stage → WebRTCStage
-
no setter
Methods
-
attach(
) → void - A view shows the stream: it gets the open session, or a new one at once.
-
detach(
) → void - A view went away; with none left, the session closes after keepAlive.
-
dispose(
) → void -
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