System::IO::Stream::BeginWrite 方法

Stream::BeginWrite method

发起异步写入操作。

virtual System::SharedPtr<System::IAsyncResult> System::IO::Stream::BeginWrite(System::ArrayPtr<uint8_t> buffer, int offset, int count, System::AsyncCallback callback, System::SharedPtr<System::Object> state)
参数类型描述
bufferSystem::ArrayPtr<uint8_t>包含待写入数据的缓冲区
offsetintbuffer 中的 0 基偏移,指示写入数据的起始位置
countint要写入的字节数
回调System::AsyncCallback操作完成时要调用的回调函数
stateSystem::SharedPtr<System::Object>用户提供的数据,用于唯一标识每个异步写入操作

ReturnValue

一个 IAsyncResult 对象,表示已启动的异步写入操作

另见