switchRoom method
Future<Map>
switchRoom(
- String fromRoomID,
- dynamic toRoomInfo,
- bool isCreateWhenRoomNotExisted,
- dynamic config,
)
Implementation
Future<Map<dynamic, dynamic>> switchRoom(
String fromRoomID,
dynamic toRoomInfo,
bool isCreateWhenRoomNotExisted,
dynamic config) async {
final result = await promiseToFuture(ZIM.getInstance()!.switchRoom(
fromRoomID,
_mapToJSObject(toRoomInfo),
isCreateWhenRoomNotExisted,
_mapToJSObject(config)))
.catchError(_handleError);
return _jsObjectToMap(result);
}