public HtmlBag Load() { var htmlBag = new HtmlBag(); foreach (var day in DateBuilder.DaysOfWeek) { htmlBag.Add(day.ToString(), GetHtml(Urls.GetUrlFor(day))); LogHelper.Information(this, $"Loading of InTheaterNow html for {day.ToString()} has finished"); } return(htmlBag); }
public HtmlBag Load(List <ScrapedData> data) { if (data == null) { throw new ArgumentException(); } var htmlBag = new HtmlBag(); //get unique ids var ids = data.GroupBy(m => m.SiteMovieId).Select(x => x.Key); foreach (var id in ids) { htmlBag.Add(id, GetHtml(Urls.GetUrlFor(id))); LogHelper.Information(this, $"Loading of Movie details - html for {id} has finished"); } return(htmlBag); }