Esempio n. 1
0
 public FileMonitor(ISolutionFilesService solutionFilesService, IGlobMatcher globMatcher, IFileChangeSubscriber fileChangeSubscriber, IOutputService outputService)
 {
     this.solutionFilesService = solutionFilesService;
     this.globMatcher = globMatcher;
     this.fileChangeSubscriber = fileChangeSubscriber;
     this.outputService = outputService;
     this.monitoredFilesField = new ConcurrentDictionary<string, MonitoredFile>();
     this.monitoredProjectsField = new ConcurrentDictionary<string, MonitoredFile>();
 }
        public DefaultFileEventListenerFactory(ISolutionFilesService solutionFilesService, IVsFileChangeEx fileChangeService, IOutputService outputService, ICommandErrorReporter errorReporter)
        {
            this.solutionFilesService = solutionFilesService;
            this.fileChangeService = fileChangeService;
            this.outputService = outputService;

            this.globMatcher = new RegexGlobMatcher();
            this.onChangeTaskDispatcher = new SynchronousOnChangeTaskDispatcher(this.outputService);
            this.actionFactory = new PowerShellGooseActionFactory(new PowerShellTaskFactory(this.outputService, errorReporter, new JsonCommandLogParser()), new PowerShellCommandBuilder());
        }
Esempio n. 3
0
        protected override void Initialize()
        {
            var solution = (IVsSolution)this.GetService(typeof(SVsSolution));

            this.solutionFilesService = new SolutionFilesService(solution);
            this.outputService = this.outputService ?? new OutputService(this);
            this.fileChangeService = this.fileChangeService ?? (IVsFileChangeEx)this.GetService(typeof(SVsFileChangeEx));

            var errorListProviderFacade = new GooseErrorListProviderFacade(this, this.solutionFilesService);
            var errorTaskHandler = new GooseErrorTaskHandler(errorListProviderFacade);
            this.errorReporter = new CommandErrorReporter(errorTaskHandler, new JsonCommandLogParser());

            var fileEventListenerFactory = new DefaultFileEventListenerFactory(solutionFilesService, this.fileChangeService, this.outputService, errorReporter);
            this.solutionEventListener = this.solutionEventListener ?? new SolutionEventListener(solution, fileEventListenerFactory, this.outputService);
            base.Initialize();
        }
 public FakeSolutionTestContext(ISolutionFilesService solutionFilesService, IFileChangeSubscriber fileChangeSubscriber)
 {
     this.solutionFilesService = solutionFilesService;
     this.fileChangeSubscriber = fileChangeSubscriber;
     this.projects = new List<ISolutionProject>();
 }
 public GooseErrorListProviderFacade(IServiceProvider provider, ISolutionFilesService solutionFiles)
     : base(provider)
 {
     this.solutionFiles = solutionFiles;
 }