public string GetPath(ResultData.MediaElement element) { if (_nameTopicTitle) { var extension = ".mp4"; return(_folder + element.topic + "-" + element.title + extension); } return(_filename); }
public Uri GetUri(ResultData.MediaElement element) { switch (_quality) { case Quality.low: return(new Uri(element.url_video_low)); case Quality.medium: return(new Uri(element.url_video)); case Quality.high: return(new Uri(element.url_video_low)); default: return(new Uri(element.url_video)); } }
public void Download(ResultData.MediaElement element, string saveLocation) { Uri uri = new Uri(element.url_video_hd); Download(uri, saveLocation); }
public Task DownloadAsync(ResultData.MediaElement element, MediathekDownloadOptions options) { return(DownloadAsync(options.GetUri(element), options.GetPath(element))); }
public void Download(ResultData.MediaElement element, MediathekDownloadOptions options) { Download(options.GetUri(element), options.GetPath(element)); }
public Task DownloadAsync(ResultData.MediaElement element, string saveLocation) { Uri uri = new Uri(element.url_video_hd); return(DownloadAsync(uri, saveLocation)); }