public SolutionChecksumUpdater(RemoteHostClientService service, CancellationToken shutdownToken) : base(AggregateAsynchronousOperationListener.CreateEmptyListener(), service.Workspace.Services.GetService<IGlobalOperationNotificationService>(), service.Workspace.Options.GetOption(RemoteHostOptions.SolutionChecksumMonitorBackOffTimeSpanInMS), shutdownToken) { _service = service; _event = new SemaphoreSlim(initialCount: 0); // start listening workspace change event _service.Workspace.WorkspaceChanged += OnWorkspaceChanged; // create its own cancellation token source _globalOperationCancellationSource = CancellationTokenSource.CreateLinkedTokenSource(shutdownToken); Start(); }
public SolutionChecksumUpdater(RemoteHostClientService service, CancellationToken shutdownToken) : base(AggregateAsynchronousOperationListener.CreateEmptyListener(), service.Workspace.Services.GetService <IGlobalOperationNotificationService>(), service.Workspace.Options.GetOption(RemoteHostOptions.SolutionChecksumMonitorBackOffTimeSpanInMS), shutdownToken) { _service = service; _event = new SemaphoreSlim(initialCount: 0); // start listening workspace change event _service.Workspace.WorkspaceChanged += OnWorkspaceChanged; // create its own cancellation token source _globalOperationCancellationSource = CancellationTokenSource.CreateLinkedTokenSource(shutdownToken); Start(); }
public SolutionChecksumUpdater(RemoteHostClientService service, CancellationToken shutdownToken) : base(service.Listener, service.Workspace.Services.GetService <IGlobalOperationNotificationService>(), service.Workspace.Options.GetOption(RemoteHostOptions.SolutionChecksumMonitorBackOffTimeSpanInMS), shutdownToken) { _service = service; _textChangeQueue = new SimpleTaskQueue(TaskScheduler.Default); _event = new SemaphoreSlim(initialCount: 0); _gate = new object(); // start listening workspace change event _service.Workspace.WorkspaceChanged += OnWorkspaceChanged; // create its own cancellation token source _globalOperationCancellationSource = CancellationTokenSource.CreateLinkedTokenSource(shutdownToken); Start(); }