Channel.CreateUnbounded 方法
定义
重载
| CreateUnbounded<T>() |
创建可由任意数量的读取器和编写器同时使用的无限通道。Creates an unbounded channel usable by any number of readers and writers concurrently. |
| CreateUnbounded<T>(UnboundedChannelOptions) |
根据提供的选项创建无限通道。Creates an unbounded channel subject to the provided options. |
CreateUnbounded<T>()
创建可由任意数量的读取器和编写器同时使用的无限通道。Creates an unbounded channel usable by any number of readers and writers concurrently.
public:
generic <typename T>
static System::Threading::Channels::Channel<T> ^ CreateUnbounded();
public static System.Threading.Channels.Channel<T> CreateUnbounded<T> ();
static member CreateUnbounded : unit -> System.Threading.Channels.Channel<'T>
Public Shared Function CreateUnbounded(Of T) () As Channel(Of T)
类型参数
- T
通道中的数据类型。The type of data in the channel.
返回
创建的通道。The created channel.
适用于
CreateUnbounded<T>(UnboundedChannelOptions)
根据提供的选项创建无限通道。Creates an unbounded channel subject to the provided options.
public:
generic <typename T>
static System::Threading::Channels::Channel<T> ^ CreateUnbounded(System::Threading::Channels::UnboundedChannelOptions ^ options);
public static System.Threading.Channels.Channel<T> CreateUnbounded<T> (System.Threading.Channels.UnboundedChannelOptions options);
static member CreateUnbounded : System.Threading.Channels.UnboundedChannelOptions -> System.Threading.Channels.Channel<'T>
Public Shared Function CreateUnbounded(Of T) (options As UnboundedChannelOptions) As Channel(Of T)
类型参数
- T
指定通道中的数据类型。Specifies the type of data in the channel.
参数
- options
- UnboundedChannelOptions
用于指导通道行为的选项。Options that guide the behavior of the channel.
返回
创建的通道。The created channel.