示例#1
0
 public string DownloadImage(Uri imageUri)
 {
     var scraper = new BegemotProductScraper();
     scraper.DownloadImage(this, imageUri);
     return ImagePath;
 }
示例#2
0
        public string GetImagePath()
        {
            if (ImagePath == NoImagePath)
            {
                return NoImagePath;
            }

            if (string.IsNullOrWhiteSpace(ImagePath))
            {
                ImagePath = GenerateImagePath(Article);
            }

            bool needDownload = !File.Exists(ImagePath);

            if (needDownload)
            {
                var scraper = new BegemotProductScraper();
                scraper.DownloadImage(this);
            }

            return ImagePath;
        }
示例#3
0
        public void ScrapeInfoFromSite()
        {
            var scraper = new BegemotProductScraper();
            scraper.DownloadDescription(this);

            string descHashPath = GetDescHashPath();
            WriteHash(descHashPath);
        }