Dyn compatible(object safety) version of Write.
All implementations of Write has already implemented this trait.
Also, all implementations of DynWrite has already implemented Write.
User should not use this trait directly.
A trait for determining whether the buffer is owned or borrowed.
Poll-based I/O operations require the buffer to be borrowed, while completion-based I/O
operations require the buffer to be owned. This trait provides a way to abstract over
the ownership of the buffer. Users could switch between poll-based and completion-based
I/O operations at compile-time by enabling or disabling the completion-based feature.
Considering lots of runtimes does not require [std::marker::Send] for
[std::future::Future] and [futures_core::stream::Stream], we provide a trait to
represent the future or stream that may not require [std::marker::Send]. Users could
switch the feature no-send at compile-time to disable the [std::marker::Send] bound
for [std::future::Future] and [futures_core::stream::Stream].
The core trait for reading data,
it is similar to [std::io::Read],
but it takes the ownership of the buffer,
because completion-based IO requires the buffer to be pinned and should be safe to
cancellation.
The core trait for writing data,
it is similar to [std::io::Write], but it takes the ownership of the buffer,
because completion-based IO requires the buffer to be pinned and should be safe to
cancellation.