public void Dispose() { if (_disposed) { return; } _disposed = true; OnDisposed(); ChecksumScope.Dispose(); }
public override void Shutdown() { base.Shutdown(); // stop listening workspace change event _workspace.WorkspaceChanged -= OnWorkspaceChanged; CancelAndDispose(_globalOperationCancellationSource); // release last snapshot _lastSnapshot?.Dispose(); _lastSnapshot = null; }
public override void Shutdown() { base.Shutdown(); // stop listening workspace change event _service.Workspace.WorkspaceChanged -= OnWorkspaceChanged; CancelAndDispose(_globalOperationCancellationSource); using (_gate.DisposableWait(CancellationToken.None)) { // release last snapshot _lastSnapshot?.Dispose(); _lastSnapshot = null; } }