9[DebuggerDisplay(
"{DebuggerDisplayContent,nq}")]
46 [DebuggerDisplay(
"{DebuggerDisplayContent,nq}")]
136 return $"Block=\"{((owningSource != null) ? owningSource.Content : _owningSource)}\"";
166 item =
default(TOutput);
174 items =
new TOutput[1] {
item };
256 TOutput message =
default(TOutput);
498 return default(TOutput);
616 private object DebuggerDisplayContent =>
$"{Common.GetNameForDebugger(this, _source.DataflowBlockOptions)}, HasValue={HasValueForDebugger}, Value={ValueForDebugger}";
679 _boundingState.TaskForInputProcessing =
null;
803 _boundingState.TaskForInputProcessing =
null;
static string Argument_InvalidMessageHeader
static string InvalidOperation_MessageNotReservedByTarget
static string Argument_CantConsumeFromANullSource
readonly Func< TOutput, TOutput > _cloningFunction
readonly BroadcastBlock< TOutput > _owningSource
DebuggingInformation GetDebuggingInformation()
readonly Queue< TOutput > _messages
object DebuggerDisplayContent
bool _decliningPermanently
List< Exception > _exceptions
ITargetBlock< TOutput > _nextMessageReservedFor
readonly TargetRegistry< TOutput > _targetRegistry
TOutput ConsumeMessage(DataflowMessageHeader messageHeader, ITargetBlock< TOutput > target, out bool messageConsumed)
void OfferCurrentMessageToNewTarget(ITargetBlock< TOutput > target)
void ReleaseReservation(DataflowMessageHeader messageHeader, ITargetBlock< TOutput > target)
bool _currentMessageIsValid
void CompleteBlockIfPossible()
void OfferAsyncIfNecessary(bool isReplacementReplica=false)
readonly TaskCompletionSource< VoidResult > _completionTask
void OfferMessageToTarget(DataflowMessageHeader header, TOutput message, ITargetBlock< TOutput > target)
DataflowBlockOptions DataflowBlockOptions
void AddMessage(TOutput item)
void CompleteBlockIfPossible_Slow()
void AddException(Exception exception)
TOutput CloneItem(TOutput item)
readonly Action< int > _itemsRemovedAction
void CompleteBlockOncePossible()
BroadcastingSourceCore(BroadcastBlock< TOutput > owningSource, Func< TOutput, TOutput > cloningFunction, DataflowBlockOptions dataflowBlockOptions, Action< int > itemsRemovedAction)
Task _taskForOutputProcessing
void OfferMessagesLoopCore()
bool TryReceive(Predicate< TOutput > filter, [MaybeNullWhen(false)] out TOutput item)
bool ReserveMessage(DataflowMessageHeader messageHeader, ITargetBlock< TOutput > target)
void AddExceptions(List< Exception > exceptions)
IDisposable LinkTo(ITargetBlock< TOutput > target, DataflowLinkOptions linkOptions)
readonly DataflowBlockOptions _dataflowBlockOptions
bool TryReceiveAll([NotNullWhen(true)] out IList< TOutput > items)
DebugView(BroadcastBlock< T > broadcastBlock)
Task TaskForOutputProcessing
readonly BroadcastingSourceCore< T >.DebuggingInformation _sourceDebuggingInformation
IEnumerable< T > InputQueue
TargetRegistry< T > LinkedTargets
bool IsDecliningPermanently
ITargetBlock< T > NextMessageReservedFor
readonly BroadcastBlock< T > _broadcastBlock
void CompleteTargetIfPossible()
BroadcastBlock(Func< T, T >? cloningFunction, DataflowBlockOptions dataflowBlockOptions)
readonly BroadcastingSourceCore< T > _source
void CompleteCore(Exception exception, bool storeExceptionEvenIfAlreadyCompleting, bool revertProcessingState=false)
readonly BoundingStateWithPostponedAndTask< T > _boundingState
bool _decliningPermanently
bool TryReceive(Predicate< T >? filter, [MaybeNullWhen(false)] out T item)
IDisposable LinkTo(ITargetBlock< T > target, DataflowLinkOptions linkOptions)
override string ToString()
void OnItemsRemoved(int numItemsRemoved)
void ConsumeMessagesLoopCore()
void ConsumeAsyncIfNecessary(bool isReplacementReplica=false)
object DebuggerDisplayContent
BroadcastBlock(Func< T, T >? cloningFunction)
bool ConsumeAndStoreOneMessageIfAvailable()
TaskScheduler TaskScheduler
int ActualMaxMessagesPerTask
CancellationToken CancellationToken
Task TaskForInputProcessing
static Exception StartTaskSafe(Task task, TaskScheduler scheduler)
static TaskContinuationOptions GetContinuationOptions(TaskContinuationOptions toInclude=TaskContinuationOptions.None)
static void PropagateCompletionOnceCompleted(Task sourceCompletionTask, IDataflowBlock target)
static TaskCreationOptions GetCreationOptionsForTask(bool isReplacementReplica=false)
static string GetNameForDebugger(IDataflowBlock block, DataflowBlockOptions options=null)
static void AddException([NotNull] ref List< Exception > list, Exception exception, bool unwrapInnerExceptions=false)
static void WireCancellationToComplete(CancellationToken cancellationToken, Task completionTask, Action< object > completeAction, object completeState)
static int GetBlockId(IDataflowBlock block)
static readonly DataflowEtwProvider Log
static readonly IDisposable Nop
LinkedTargetInfo FirstTargetNode
void PropagateCompletion(LinkedTargetInfo firstTarget)
LinkedTargetInfo ClearEntryPoints()
void Remove(ITargetBlock< T > target, bool onlyIfReachedMaxMessages=false)
void Add(ref ITargetBlock< T > target, DataflowLinkOptions linkOptions)
static TaskScheduler Default
Task ContinueWith(Action< Task< TResult > > continuationAction)
static new TaskFactory< TResult > Factory
static bool Read(ref bool location)
void Fault(Exception exception)
bool IsCancellationRequested
static CancellationToken None