Esempio n. 1
0
        static void Main(string[] args)
        {
            //TODO -> Parse them motherfucking addresses (sepereate address from postal codes .... )
            DataManager dataManager = new DataManager("kt");
            DateManager dateManager = new DateManager(dataManager.getLastScrapeDate());

            //SQLParser sp = new SQLParser(dataManager.getScrapedDataFileName());

            foreach (DateTime date in dateManager.Generate())
            {
                Console.WriteLine("Current date being scraped: " + date.ToString());
                ID id = new ID(date.Day, date.Month, date.Year);
                dataManager.writeParameters(id);
                RSK_Scraper scraper = new RSK_Scraper(dataManager, date.ToString("M/d/yyyy"));

            }
            dataManager.writeToSQLServer();
            Console.WriteLine("Finished, press enter to continue");
            Console.ReadLine();
        }
Esempio n. 2
0
 public void writeParameters(ID id)
 {
     File.Delete(PARAMETER_FILENAME);
     using (var file = new StreamWriter(PARAMETER_FILENAME, true))
     {
         foreach (string socialId in id.Generate())
         {
             file.WriteLine(socialId);
         }
     }
     loadParameters();
 }