1 write to _boundingState
System.Threading.Tasks.Dataflow (1)
Blocks\BufferBlock.cs (1)
58_boundingState = new BoundingStateWithPostponedAndTask<T>(dataflowBlockOptions.BoundedCapacity);
42 references to _boundingState
System.Threading.Tasks.Dataflow (42)
Blocks\BufferBlock.cs (42)
109if (_boundingState == null 111(_boundingState.CountIsLessThanBound && _boundingState.PostponedMessages.Count == 0 && _boundingState.TaskForInputProcessing == null)) 125if (_boundingState != null) _boundingState.CurrentCount++; 132Debug.Assert(_boundingState != null && _boundingState.PostponedMessages != null, 135_boundingState.PostponedMessages.Push(source, messageHeader); 171Debug.Assert(_boundingState != null && _boundingState.TaskForInputProcessing != null, 173_boundingState.TaskForInputProcessing = null; 225if (_boundingState != null) 230Debug.Assert(_boundingState.CurrentCount - numItemsRemoved >= 0, 232_boundingState.CurrentCount -= numItemsRemoved; 245Debug.Assert(_boundingState != null, "Must be in bounded mode."); 248_boundingState.TaskForInputProcessing == null && 249_boundingState.PostponedMessages.Count > 0 && 250_boundingState.CountIsLessThanBound) 254_boundingState.TaskForInputProcessing = 262this, _boundingState.TaskForInputProcessing, DataflowEtwProvider.TaskLaunchedReason.ProcessingInputMessages, 263_boundingState.PostponedMessages.Count); 267Exception? exception = Common.StartTaskSafe(_boundingState.TaskForInputProcessing, _source.DataflowBlockOptions.TaskScheduler); 281Debug.Assert(_boundingState != null && _boundingState.TaskForInputProcessing != null, 283Debug.Assert(_boundingState.TaskForInputProcessing.Id == Task.CurrentId, 305_boundingState.TaskForInputProcessing = null; 327Debug.Assert(_boundingState != null && _boundingState.TaskForInputProcessing != null, 329Debug.Assert(_boundingState.TaskForInputProcessing.Id == Task.CurrentId, 341if (!_boundingState.CountIsLessThanBound) return false; 342if (!_boundingState.PostponedMessages.TryPop(out sourceAndMessage)) return false; 346_boundingState.CurrentCount++; 365lock (IncomingLock) _boundingState.CurrentCount--; 377(_boundingState == null || _boundingState.TaskForInputProcessing == null)) 383if (_boundingState != null && _boundingState.PostponedMessages.Count > 0) 391if (thisBufferBlock._boundingState != null) 395thisBufferBlock._boundingState.PostponedMessages, 450get { return _bufferBlock._boundingState?.PostponedMessages; } 456public Task? TaskForInputProcessing { get { return _bufferBlock._boundingState?.TaskForInputProcessing; } }