toMap static method
Implementation
static Map<String, Object> toMap(DownloadSelections downloadSelections) {
Map<String, Object> downloadSelectionMap = HashMap();
downloadSelectionMap['selectedVideoTrackId'] = downloadSelections
._downloadOptions
.allVideo[downloadSelections._selectedVideoTrackIndex]
.id;
if (downloadSelections._selectedAudioTrackIndex != -1) {
downloadSelectionMap['selectedAudioTrackId'] = downloadSelections
._downloadOptions
.allAudio[downloadSelections._selectedAudioTrackIndex]
.id;
}
downloadSelectionMap['downloadOptions'] =
DownloadOptions.toMap(downloadSelections._downloadOptions);
return downloadSelectionMap;
}