BroadcastBlock Class
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Provides a buffer for storing at most one element at time, overwriting each message with the next as it arrives.
generic
public ref class BroadcastBlock sealed : System::Threading::Tasks::Dataflow::IPropagatorBlock, System::Threading::Tasks::Dataflow::IReceivableSourceBlock, System::Threading::Tasks::Dataflow::ISourceBlock, System::Threading::Tasks::Dataflow::ITargetBlock
public sealed class BroadcastBlock : System.Threading.Tasks.Dataflow.IPropagatorBlock, System.Threading.Tasks.Dataflow.IReceivableSourceBlock, System.Threading.Tasks.Dataflow.ISourceBlock, System.Threading.Tasks.Dataflow.ITargetBlock
type BroadcastBlock<'T> = class
interface IPropagatorBlock<'T, 'T>
interface ITargetBlock<'T>
interface IDataflowBlock
interface ISourceBlock<'T>
interface IReceivableSourceBlock<'T>
type BroadcastBlock<'T> = class
interface IDataflowBlock
interface IPropagatorBlock<'T, 'T>
interface ISourceBlock<'T>
interface ITargetBlock<'T>
interface IReceivableSourceBlock<'T>
Public NotInheritable Class BroadcastBlock(Of T)
Implements IPropagatorBlock(Of T, T), IReceivableSourceBlock(Of T), ISourceBlock(Of T), ITargetBlock(Of T)
Type Parameters
- T
Specifies the type of the data buffered by this dataflow block.
- Inheritance
-
BroadcastBlock
- Implements
Remarks
BroadcastBlock
Constructors
| Name | Description |
|---|---|
|
BroadcastBlock |
Initializes the BroadcastBlock |
|
BroadcastBlock |
Initializes the BroadcastBlock |
Properties
| Name | Description |
|---|---|
| Completion |
Gets a Task that represents the asynchronous operation and completion of the dataflow block. |
Methods
| Name | Description |
|---|---|
| Complete() |
Signals to the IDataflowBlock that it should not accept nor produce any more messages nor consume any more postponed messages. |
| Equals(Object) |
Determines whether the specified object is equal to the current object. (Inherited from Object) |
| GetHashCode() |
Serves as the default hash function. (Inherited from Object) |
| GetType() |
Gets the Type of the current instance. (Inherited from Object) |
|
LinkTo(ITargetBlock |
Links the ISourceBlock |
| MemberwiseClone() |
Creates a shallow copy of the current Object. (Inherited from Object) |
| ToString() |
Returns a string that represents the formatted name of this IDataflowBlock instance. |
|
TryReceive(Predicate |
Attempts to synchronously receive an available output item from the IReceivableSourceBlock |
Explicit Interface Implementations
| Name | Description |
|---|---|
| IDataflowBlock.Fault(Exception) |
Causes the IDataflowBlock to complete in a Faulted state. |
|
IReceivableSourceBlock |
Attempts to synchronously receive all available items from the IReceivableSourceBlock |
|
ISourceBlock |
Called by a linked ITargetBlock |
|
ISourceBlock |
Called by a linked ITargetBlock |
|
ISourceBlock |
Called by a linked ITargetBlock |
|
ITargetBlock |
Offers a message to the ITargetBlock |
Extension Methods
| Name | Description |
|---|---|
|
AsObservable |
Creates a new IObservable |
|
AsObserver |
Creates a new IObserver |
|
LinkTo |
Links the ISourceBlock |
|
LinkTo |
Links the ISourceBlock |
|
LinkTo |
Links the ISourceBlock |
|
OutputAvailableAsync |
Provides a Task |
|
OutputAvailableAsync |
Provides a Task |
|
Post |
Posts an item to the ITargetBlock |
|
Receive |
Synchronously receives a value from a specified source and provides a token to cancel the operation. |
|
Receive |
Synchronously receives a value from a specified source, providing a token to cancel the operation and observing an optional time-out interval. |
|
Receive |
Synchronously receives a value from a specified source, observing an optional time-out period. |
|
Receive |
Synchronously receives a value from a specified source. |
|
ReceiveAllAsync |
Creates an IAsyncEnumerable |
|
ReceiveAsync |
Asynchronously receives a value from a specified source and provides a token to cancel the operation. |
|
ReceiveAsync |
Asynchronously receives a value from a specified source, providing a token to cancel the operation and observing an optional time-out interval. |
|
ReceiveAsync |
Asynchronously receives a value from a specified source, observing an optional time-out period. |
|
ReceiveAsync |
Asynchronously receives a value from a specified source. |
|
SendAsync |
Asynchronously offers a message to the target message block, allowing for postponement. |
|
SendAsync |
Asynchronously offers a message to the target message block, allowing for postponement. |
|
TryReceive |
Attempts to synchronously receive an item from the ISourceBlock |