public void Setup(string local)
 {
     indexFile = new IndexFile(local);
     if (AsyncMode)
     {
         service  = new ConcurrentQueueService();
         consumer = Task.Factory.StartNew(service.Dequeue);
     }
 }
Exemple #2
0
        private void ProcessScript(string url, List <INode> nodes)
        {
            ConcurrentQueueService scriptService = new ConcurrentQueueService();

            foreach (IElement script in nodes)
            {
                if (script.HasAttribute("src"))
                {
                    var srcurl           = script.GetAttribute("src");
                    var srcUrlNormalized = new Uri(new Uri(url), srcurl);
                }
            }
        }
Exemple #3
0
        public void Setup(string local)
        {
            indexFile    = new IndexFile(local);
            downloadHtml = new DownloadFileQueue()
            {
                Extension = ".html"
            };
            downloadHtml.Setup("WebPages");

            downloadImges = new DownloadFileQueue()
            {
                Extension = ".jpg"
            };
            downloadImges.Setup("images");

            if (AsyncMode)
            {
                service  = new ConcurrentQueueService();
                consumer = Task.Factory.StartNew(service.Dequeue);
            }
        }