public void ProcessCatalog(ConflictCatalogProcessorArguments arguments) { Argument.AssertIsNotNull(arguments, nameof(arguments)); Logger.Log.Info("Clearing imported conflicts..."); this.importedConflictRepository.DeleteAll(); Logger.Log.Info("Cleared imported conflicts."); Logger.Log.Info($"Starting to process {arguments.FileName}..."); this.importConflictCatalogFileService.Import(arguments.FileName, this.importedConflictRepository); }
static void Main(string[] args) { Logger.SetLogger(new ConsoleLogger()); try { var arguments = new ConflictCatalogProcessorArguments(); arguments.FileName = Config.FileName; var processor = new ConflictCatalogProcessor( new ImportConflictCatalogFileService(), new ImportedConflictRepository(new SingletonSqliteConnectionProvider(Config.ConnectionString))); processor.ProcessCatalog(arguments); } catch (Exception ex) { Logger.Log.Error(ex); } Console.ReadKey(); }