stopForwardStreamToRooms method
@detail api @author shenpengliang @brief Call to this method to stop relaying media stream to all rooms after calling startForwardStreamToRooms{@link #RTCRoom#startForwardStreamToRooms}. @return - 0: Success. - < 0 : Fail. See ReturnStatus{@link #ReturnStatus} for more details. @note - Call this method will trigger onForwardStreamStateChanged{@link #IRTCRoomEventHandler#onForwardStreamStateChanged}. - The other users in the room will receive callback of onUserJoined{@link #IRTCRoomEventHandler#onUserJoined}, onUserPublishStreamVideo{@link #IRTCRoomEventHandler#onUserPublishStreamVideo}, onUserPublishStreamAudio{@link #IRTCRoomEventHandler#onUserPublishStreamAudio} when you stop relaying. - To stop relaying media stream to specific rooms, call updateForwardStreamToRooms{@link #RTCRoom#updateForwardStreamToRooms} instead. - To resume the relaying in a short time, call pauseForwardStreamToAllRooms{@link #RTCRoom#pauseForwardStreamToAllRooms} instead and then call resumeForwardStreamToAllRooms{@link #RTCRoom#resumeForwardStreamToAllRooms} to resume after that.
Implementation
Future<int?> stopForwardStreamToRooms() async {
$a() => ($instance as $p_a.RTCRoom).stopForwardStreamToRooms();
$i() => ($instance as $p_i.ByteRTCRoom).stopForwardStreamToRooms();
if (Platform.isAndroid) {
return $a();
} else if (Platform.isIOS) {
return $i();
} else {
throw UnsupportedError(
'Not Support Platform ${Platform.operatingSystem}');
}
}