CreateMediaSFURoomOptions.fromMap constructor
CreateMediaSFURoomOptions.fromMap(
- Map<String, dynamic> map
)
Implementation
factory CreateMediaSFURoomOptions.fromMap(Map<String, dynamic> map) {
return CreateMediaSFURoomOptions(
action: map['action'] != null ? map['action'] as String : "",
duration: map['duration'] != null ? map['duration'] as int : 0,
capacity: map['capacity'] != null ? map['capacity'] as int : 0,
userName: map['userName'] != null ? map['userName'] as String : "",
scheduledDate:
map['scheduledDate'] != null ? map['scheduledDate'] as int : null,
secureCode:
map['secureCode'] != null ? map['secureCode'] as String : "",
eventType: map['eventType'] != null
? EventType.values.firstWhere(
(e) => e.toString().split('.').last == map['eventType'])
: null,
meetingRoomParams: map['meetingRoomParams'] != null
? MeetingRoomParams.fromJson(map['meetingRoomParams'])
: null,
recordingParams: map['recordingParams'] != null
? RecordingParams.fromJson(map['recordingParams'])
: null,
recordOnly:
map['recordOnly'] != null ? map['recordOnly'] as bool : false,
safeRoom: map['safeRoom'] != null ? map['safeRoom'] as bool : false,
autoStartSafeRoom: map['autoStartSafeRoom'] != null
? map['autoStartSafeRoom'] as bool
: false,
safeRoomAction: map['safeRoomAction'] != null
? map['safeRoomAction'] as String
: "",
dataBuffer:
map['dataBuffer'] != null ? map['dataBuffer'] as bool : false,
bufferType:
map['bufferType'] != null ? map['bufferType'] as String : "",
supportSIP:
map['supportSIP'] != null ? map['supportSIP'] as bool : false,
directionSIP: map['directionSIP'] != null
? map['directionSIP'] as String
: "both",
preferPCMA:
map['preferPCMA'] != null ? map['preferPCMA'] as bool : false,
supportTranslation: map['supportTranslation'] != null
? map['supportTranslation'] as bool
: false,
translationConfigNickName: map['translationConfigNickName'] != null
? map['translationConfigNickName'] as String
: "",
supportFlexRoom: map['supportFlexRoom'] != null
? map['supportFlexRoom'] as bool
: false,
supportMaxRoom: map['supportMaxRoom'] != null
? map['supportMaxRoom'] as bool
: false);
}