pub struct FsOutputStreamWrapper { /* private fields */ }Expand description
Wrapper for fs-core OutputStream that implements HostOutputStream
Implementations§
Trait Implementations§
Source§impl HostOutputStream for FsOutputStreamWrapper
impl HostOutputStream for FsOutputStreamWrapper
Source§fn write(&mut self, bytes: Bytes) -> StreamResult<()>
fn write(&mut self, bytes: Bytes) -> StreamResult<()>
Write bytes after obtaining a permit to write those bytes Read more
Source§fn flush(&mut self) -> StreamResult<()>
fn flush(&mut self) -> StreamResult<()>
Trigger a flush of any bytes buffered in this stream implementation. Read more
Source§fn check_write(&mut self) -> StreamResult<usize>
fn check_write(&mut self) -> StreamResult<usize>
Returns the number of bytes that are ready to be written to this stream. Read more
Source§fn blocking_write_and_flush<'life0, 'async_trait>(
&'life0 mut self,
bytes: Bytes,
) -> Pin<Box<dyn Future<Output = Result<(), StreamError>> + Send + 'async_trait>>where
'life0: 'async_trait,
Self: Send + 'async_trait,
fn blocking_write_and_flush<'life0, 'async_trait>(
&'life0 mut self,
bytes: Bytes,
) -> Pin<Box<dyn Future<Output = Result<(), StreamError>> + Send + 'async_trait>>where
'life0: 'async_trait,
Self: Send + 'async_trait,
Perform a write of up to 4096 bytes, and then flush the stream. Block
until all of these operations are complete, or an error occurs. Read more
Source§fn write_zeroes(&mut self, nelem: usize) -> Result<(), StreamError>
fn write_zeroes(&mut self, nelem: usize) -> Result<(), StreamError>
Repeatedly write a byte to a stream.
Important: this write must be non-blocking!
Returning an Err which downcasts to a
StreamError will be
reported to Wasm as the empty error result. Otherwise, errors will trap.Source§fn blocking_write_zeroes_and_flush<'life0, 'async_trait>(
&'life0 mut self,
nelem: usize,
) -> Pin<Box<dyn Future<Output = Result<(), StreamError>> + Send + 'async_trait>>where
'life0: 'async_trait,
Self: Send + 'async_trait,
fn blocking_write_zeroes_and_flush<'life0, 'async_trait>(
&'life0 mut self,
nelem: usize,
) -> Pin<Box<dyn Future<Output = Result<(), StreamError>> + Send + 'async_trait>>where
'life0: 'async_trait,
Self: Send + 'async_trait,
Perform a write of up to 4096 zeroes, and then flush the stream.
Block until all of these operations are complete, or an error
occurs. Read more
Source§fn write_ready<'life0, 'async_trait>(
&'life0 mut self,
) -> Pin<Box<dyn Future<Output = Result<usize, StreamError>> + Send + 'async_trait>>where
'life0: 'async_trait,
Self: Send + 'async_trait,
fn write_ready<'life0, 'async_trait>(
&'life0 mut self,
) -> Pin<Box<dyn Future<Output = Result<usize, StreamError>> + Send + 'async_trait>>where
'life0: 'async_trait,
Self: Send + 'async_trait,
Simultaneously waits for this stream to be writable and then returns how
much may be written or the last error that happened.
Source§impl Subscribe for FsOutputStreamWrapper
impl Subscribe for FsOutputStreamWrapper
Auto Trait Implementations§
impl Freeze for FsOutputStreamWrapper
impl !RefUnwindSafe for FsOutputStreamWrapper
impl Send for FsOutputStreamWrapper
impl Sync for FsOutputStreamWrapper
impl Unpin for FsOutputStreamWrapper
impl UnsafeUnpin for FsOutputStreamWrapper
impl !UnwindSafe for FsOutputStreamWrapper
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
Source§impl<T> GetSetFdFlags for T
impl<T> GetSetFdFlags for T
Source§fn get_fd_flags(&self) -> Result<FdFlags, Error>where
T: AsFilelike,
fn get_fd_flags(&self) -> Result<FdFlags, Error>where
T: AsFilelike,
Query the “status” flags for the
self file descriptor.Source§fn new_set_fd_flags(&self, fd_flags: FdFlags) -> Result<SetFdFlags<T>, Error>where
T: AsFilelike,
fn new_set_fd_flags(&self, fd_flags: FdFlags) -> Result<SetFdFlags<T>, Error>where
T: AsFilelike,
Source§fn set_fd_flags(&mut self, set_fd_flags: SetFdFlags<T>) -> Result<(), Error>where
T: AsFilelike,
fn set_fd_flags(&mut self, set_fd_flags: SetFdFlags<T>) -> Result<(), Error>where
T: AsFilelike,
Set the “status” flags for the
self file descriptor. Read moreSource§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more