pub trait WriteDyn:
Unpin
+ Send
+ Sync {
// Required methods
fn write_dyn(&mut self, bs: Buffer) -> BoxedFuture<'_, Result<()>>;
fn close_dyn(&mut self) -> BoxedFuture<'_, Result<Metadata>>;
fn abort_dyn(&mut self) -> BoxedFuture<'_, Result<()>>;
}
Expand description
WriteDyn is the dyn version of Write
make it possible to use as
Box<dyn WriteDyn>
.
Required Methods§
Sourcefn write_dyn(&mut self, bs: Buffer) -> BoxedFuture<'_, Result<()>>
fn write_dyn(&mut self, bs: Buffer) -> BoxedFuture<'_, Result<()>>
The dyn version of Write::write
.
Sourcefn close_dyn(&mut self) -> BoxedFuture<'_, Result<Metadata>>
fn close_dyn(&mut self) -> BoxedFuture<'_, Result<Metadata>>
The dyn version of Write::close
.
Sourcefn abort_dyn(&mut self) -> BoxedFuture<'_, Result<()>>
fn abort_dyn(&mut self) -> BoxedFuture<'_, Result<()>>
The dyn version of Write::abort
.