Ejemplo n.º 1
0
 protected override void End()
 {
     Parallel.ForEach(data, d =>
     {
         IHttpHelper http = new PuppeteerSharpHttpHelper();
         new _34hfPage()
             .SetSavePath($@"{savePath}{d.Key}\")
             .StartWithUrlAsync(d.Key).Wait();
     }
     base.End();
 }
Ejemplo n.º 2
0
        protected override void Parse(IHtmlDocument html)
        {
            var m3 = new m3()
                     .SetLogger(_log)
                     .SetHttpHelper(_Http);

            IHttpHelper http = new PuppeteerSharpHttpHelper();
            var         dbc  = html.QuerySelector(".dbc").TextContent.Trim();
            var         ll   = html.QuerySelector("#video-list").TextContent.Trim();
            var         imgs = html.QuerySelectorAll(".slides img").Select(m => m.GetAttribute("src"));
            var         down = html.QuerySelector(".download_dz a").GetAttribute("href");

            Console.WriteLine(dbc);
            Console.WriteLine(ll);
            foreach (var i in imgs)
            {
                Console.WriteLine(i);
            }
            m3.StartWithUrlAsync(down).Wait();
        }