void async_write(SyncWriteStreamT &s, const ConstBufferT &buf, const ComplateConditionT &condition, const HandlerT &handler) { typedef detail::write_handler_t<SyncWriteStreamT, ConstBufferT, ComplateConditionT, HandlerT> HookWriteHandler; std::uint32_t send_len = detail::MAX_BUFFER_LEN > buf.size() ? buf.size() : detail::MAX_BUFFER_LEN; s.async_write(buffer(buf.data(), send_len), HookWriteHandler(s, buf, buf.size(), condition, 0, handler)); }
size_t Write(const ConstBufferT &buffer, const u_int64 &offset) { return impl_->Write(buffer.data(), buffer.size(), offset); }
size_t Write(const ConstBufferT &buffer) { return impl_->Write(buffer.data(), buffer.size(), 0); }
void AsyncWrite(const ConstBufferT &buffer, const u_int64 &offset, const HandlerT &callback) { return impl_->AsyncWrite(buffer.data(), buffer.size(), offset, callback); }