onUserJoined property
Occurs when a remote user (COMMUNICATION)/ host (LIVE_BROADCASTING) joins the channel.
In a communication channel, this callback indicates that a remote user joins the channel. The SDK also triggers this callback to report the existing users in the channel when a user joins the channel.In a live-broadcast channel, this callback indicates that a host joins the channel. The SDK also triggers this callback to report the existing hosts in the channel when a host joins the channel. Agora recommends limiting the number of hosts to 17.The SDK triggers this callback under one of the following circumstances:A remote user/host joins the channel by calling the joinChannel 2/2
method.A remote user switches the user role to the host after joining the channel.A remote user/host rejoins the channel after a network interruption.
connection
The connection information. See RtcConnection .remoteUid
The ID of the user or host who joins the channel.elapsed
Time delay (ms) from the local user calling joinChannel2/2
until this callback is triggered.
Implementation
final void Function(RtcConnection connection, int remoteUid, int elapsed)?
onUserJoined;