SingleStreamDataAdapterTesterRunAsync(ReadOnlyMemoryByte, Int32, Int32, Int32, CancellationToken) 方法
异步运行数据适配器测试。
命名空间: TouchSocket.Core程序集: TouchSocket.Core (在 TouchSocket.Core.dll 中) 版本:4.1.4.7+7f7e1f78093c99347956e09330d5d7aca1d2bdf2
public Task<TimeSpan> RunAsync(
ReadOnlyMemory<byte> memory,
int testCount,
int expectedCount,
int bufferLength,
CancellationToken cancellationToken
)
Public Function RunAsync (
memory As ReadOnlyMemory(Of Byte),
testCount As Integer,
expectedCount As Integer,
bufferLength As Integer,
cancellationToken As CancellationToken
) As Task(Of TimeSpan)
member RunAsync :
memory : ReadOnlyMemory<byte> *
testCount : int *
expectedCount : int *
bufferLength : int *
cancellationToken : CancellationToken -> Task<TimeSpan>
- memory ReadOnlyMemoryByte
- 要发送的数据内存块。
- testCount Int32
- 测试发送次数。
- expectedCount Int32
- 预期接收次数。
- bufferLength Int32
- 每次写入的缓冲区长度。
- cancellationToken CancellationToken
- 取消令牌。
TaskTimeSpan返回测试所用的时间。