Trait ux::prelude::OutputStreamExt [−]
pub trait OutputStreamExt: 'static {
Show methods
pub fn clear_pending(&self);
pub fn close<P>(&self, cancellable: Option<&P>) -> Result<(), Error>
where
P: IsA<Cancellable>;
pub fn close_async<P, Q>(
&self,
io_priority: Priority,
cancellable: Option<&P>,
callback: Q
)
where
P: IsA<Cancellable>,
Q: 'static + FnOnce(Result<(), Error>) + Send;
pub fn close_async_future(
&self,
io_priority: Priority
) -> Pin<Box<dyn Future<Output = Result<(), Error>> + 'static, Global>>;
pub fn flush<P>(&self, cancellable: Option<&P>) -> Result<(), Error>
where
P: IsA<Cancellable>;
pub fn flush_async<P, Q>(
&self,
io_priority: Priority,
cancellable: Option<&P>,
callback: Q
)
where
P: IsA<Cancellable>,
Q: 'static + FnOnce(Result<(), Error>) + Send;
pub fn flush_async_future(
&self,
io_priority: Priority
) -> Pin<Box<dyn Future<Output = Result<(), Error>> + 'static, Global>>;
pub fn has_pending(&self) -> bool;
pub fn is_closed(&self) -> bool;
pub fn is_closing(&self) -> bool;
pub fn set_pending(&self) -> Result<(), Error>;
pub fn splice<P, Q>(
&self,
source: &P,
flags: OutputStreamSpliceFlags,
cancellable: Option<&Q>
) -> Result<isize, Error>
where
P: IsA<InputStream>,
Q: IsA<Cancellable>;
pub fn splice_async<P, Q, R>(
&self,
source: &P,
flags: OutputStreamSpliceFlags,
io_priority: Priority,
cancellable: Option<&Q>,
callback: R
)
where
P: IsA<InputStream>,
Q: IsA<Cancellable>,
R: 'static + FnOnce(Result<isize, Error>) + Send;
pub fn splice_async_future<P>(
&self,
source: &P,
flags: OutputStreamSpliceFlags,
io_priority: Priority
) -> Pin<Box<dyn Future<Output = Result<isize, Error>> + 'static, Global>>
where
P: 'static + IsA<InputStream> + Clone;
pub fn write<P>(
&self,
buffer: &[u8],
cancellable: Option<&P>
) -> Result<isize, Error>
where
P: IsA<Cancellable>;
pub fn write_bytes<P>(
&self,
bytes: &Bytes,
cancellable: Option<&P>
) -> Result<isize, Error>
where
P: IsA<Cancellable>;
pub fn write_bytes_async<P, Q>(
&self,
bytes: &Bytes,
io_priority: Priority,
cancellable: Option<&P>,
callback: Q
)
where
P: IsA<Cancellable>,
Q: 'static + FnOnce(Result<isize, Error>) + Send;
pub fn write_bytes_async_future(
&self,
bytes: &Bytes,
io_priority: Priority
) -> Pin<Box<dyn Future<Output = Result<isize, Error>> + 'static, Global>>;
}Required methods
pub fn clear_pending(&self)
pub fn close<P>(&self, cancellable: Option<&P>) -> Result<(), Error> where
P: IsA<Cancellable>,
P: IsA<Cancellable>,
pub fn close_async<P, Q>(
&self,
io_priority: Priority,
cancellable: Option<&P>,
callback: Q
) where
P: IsA<Cancellable>,
Q: 'static + FnOnce(Result<(), Error>) + Send,
&self,
io_priority: Priority,
cancellable: Option<&P>,
callback: Q
) where
P: IsA<Cancellable>,
Q: 'static + FnOnce(Result<(), Error>) + Send,
pub fn close_async_future(
&self,
io_priority: Priority
) -> Pin<Box<dyn Future<Output = Result<(), Error>> + 'static, Global>>
&self,
io_priority: Priority
) -> Pin<Box<dyn Future<Output = Result<(), Error>> + 'static, Global>>
pub fn flush<P>(&self, cancellable: Option<&P>) -> Result<(), Error> where
P: IsA<Cancellable>,
P: IsA<Cancellable>,
pub fn flush_async<P, Q>(
&self,
io_priority: Priority,
cancellable: Option<&P>,
callback: Q
) where
P: IsA<Cancellable>,
Q: 'static + FnOnce(Result<(), Error>) + Send,
&self,
io_priority: Priority,
cancellable: Option<&P>,
callback: Q
) where
P: IsA<Cancellable>,
Q: 'static + FnOnce(Result<(), Error>) + Send,
pub fn flush_async_future(
&self,
io_priority: Priority
) -> Pin<Box<dyn Future<Output = Result<(), Error>> + 'static, Global>>
&self,
io_priority: Priority
) -> Pin<Box<dyn Future<Output = Result<(), Error>> + 'static, Global>>
pub fn has_pending(&self) -> bool
pub fn is_closed(&self) -> bool
pub fn is_closing(&self) -> bool
pub fn set_pending(&self) -> Result<(), Error>
pub fn splice<P, Q>(
&self,
source: &P,
flags: OutputStreamSpliceFlags,
cancellable: Option<&Q>
) -> Result<isize, Error> where
P: IsA<InputStream>,
Q: IsA<Cancellable>,
&self,
source: &P,
flags: OutputStreamSpliceFlags,
cancellable: Option<&Q>
) -> Result<isize, Error> where
P: IsA<InputStream>,
Q: IsA<Cancellable>,
pub fn splice_async<P, Q, R>(
&self,
source: &P,
flags: OutputStreamSpliceFlags,
io_priority: Priority,
cancellable: Option<&Q>,
callback: R
) where
P: IsA<InputStream>,
Q: IsA<Cancellable>,
R: 'static + FnOnce(Result<isize, Error>) + Send,
&self,
source: &P,
flags: OutputStreamSpliceFlags,
io_priority: Priority,
cancellable: Option<&Q>,
callback: R
) where
P: IsA<InputStream>,
Q: IsA<Cancellable>,
R: 'static + FnOnce(Result<isize, Error>) + Send,
pub fn splice_async_future<P>(
&self,
source: &P,
flags: OutputStreamSpliceFlags,
io_priority: Priority
) -> Pin<Box<dyn Future<Output = Result<isize, Error>> + 'static, Global>> where
P: 'static + IsA<InputStream> + Clone,
&self,
source: &P,
flags: OutputStreamSpliceFlags,
io_priority: Priority
) -> Pin<Box<dyn Future<Output = Result<isize, Error>> + 'static, Global>> where
P: 'static + IsA<InputStream> + Clone,
pub fn write<P>(
&self,
buffer: &[u8],
cancellable: Option<&P>
) -> Result<isize, Error> where
P: IsA<Cancellable>,
&self,
buffer: &[u8],
cancellable: Option<&P>
) -> Result<isize, Error> where
P: IsA<Cancellable>,
pub fn write_bytes<P>(
&self,
bytes: &Bytes,
cancellable: Option<&P>
) -> Result<isize, Error> where
P: IsA<Cancellable>,
&self,
bytes: &Bytes,
cancellable: Option<&P>
) -> Result<isize, Error> where
P: IsA<Cancellable>,
pub fn write_bytes_async<P, Q>(
&self,
bytes: &Bytes,
io_priority: Priority,
cancellable: Option<&P>,
callback: Q
) where
P: IsA<Cancellable>,
Q: 'static + FnOnce(Result<isize, Error>) + Send,
&self,
bytes: &Bytes,
io_priority: Priority,
cancellable: Option<&P>,
callback: Q
) where
P: IsA<Cancellable>,
Q: 'static + FnOnce(Result<isize, Error>) + Send,
pub fn write_bytes_async_future(
&self,
bytes: &Bytes,
io_priority: Priority
) -> Pin<Box<dyn Future<Output = Result<isize, Error>> + 'static, Global>>
&self,
bytes: &Bytes,
io_priority: Priority
) -> Pin<Box<dyn Future<Output = Result<isize, Error>> + 'static, Global>>
Implementors
impl<O> OutputStreamExt for O where
O: IsA<OutputStream>,
O: IsA<OutputStream>,
pub fn clear_pending(&self)
pub fn close<P>(&self, cancellable: Option<&P>) -> Result<(), Error> where
P: IsA<Cancellable>,
P: IsA<Cancellable>,
pub fn close_async<P, Q>(
&self,
io_priority: Priority,
cancellable: Option<&P>,
callback: Q
) where
P: IsA<Cancellable>,
Q: 'static + FnOnce(Result<(), Error>) + Send,
&self,
io_priority: Priority,
cancellable: Option<&P>,
callback: Q
) where
P: IsA<Cancellable>,
Q: 'static + FnOnce(Result<(), Error>) + Send,
pub fn close_async_future(
&self,
io_priority: Priority
) -> Pin<Box<dyn Future<Output = Result<(), Error>> + 'static, Global>>
&self,
io_priority: Priority
) -> Pin<Box<dyn Future<Output = Result<(), Error>> + 'static, Global>>
pub fn flush<P>(&self, cancellable: Option<&P>) -> Result<(), Error> where
P: IsA<Cancellable>,
P: IsA<Cancellable>,
pub fn flush_async<P, Q>(
&self,
io_priority: Priority,
cancellable: Option<&P>,
callback: Q
) where
P: IsA<Cancellable>,
Q: 'static + FnOnce(Result<(), Error>) + Send,
&self,
io_priority: Priority,
cancellable: Option<&P>,
callback: Q
) where
P: IsA<Cancellable>,
Q: 'static + FnOnce(Result<(), Error>) + Send,
pub fn flush_async_future(
&self,
io_priority: Priority
) -> Pin<Box<dyn Future<Output = Result<(), Error>> + 'static, Global>>
&self,
io_priority: Priority
) -> Pin<Box<dyn Future<Output = Result<(), Error>> + 'static, Global>>
pub fn has_pending(&self) -> bool
pub fn is_closed(&self) -> bool
pub fn is_closing(&self) -> bool
pub fn set_pending(&self) -> Result<(), Error>
pub fn splice<P, Q>(
&self,
source: &P,
flags: OutputStreamSpliceFlags,
cancellable: Option<&Q>
) -> Result<isize, Error> where
P: IsA<InputStream>,
Q: IsA<Cancellable>,
&self,
source: &P,
flags: OutputStreamSpliceFlags,
cancellable: Option<&Q>
) -> Result<isize, Error> where
P: IsA<InputStream>,
Q: IsA<Cancellable>,
pub fn splice_async<P, Q, R>(
&self,
source: &P,
flags: OutputStreamSpliceFlags,
io_priority: Priority,
cancellable: Option<&Q>,
callback: R
) where
P: IsA<InputStream>,
Q: IsA<Cancellable>,
R: 'static + FnOnce(Result<isize, Error>) + Send,
&self,
source: &P,
flags: OutputStreamSpliceFlags,
io_priority: Priority,
cancellable: Option<&Q>,
callback: R
) where
P: IsA<InputStream>,
Q: IsA<Cancellable>,
R: 'static + FnOnce(Result<isize, Error>) + Send,
pub fn splice_async_future<P>(
&self,
source: &P,
flags: OutputStreamSpliceFlags,
io_priority: Priority
) -> Pin<Box<dyn Future<Output = Result<isize, Error>> + 'static, Global>> where
P: 'static + IsA<InputStream> + Clone,
&self,
source: &P,
flags: OutputStreamSpliceFlags,
io_priority: Priority
) -> Pin<Box<dyn Future<Output = Result<isize, Error>> + 'static, Global>> where
P: 'static + IsA<InputStream> + Clone,
pub fn write<P>(
&self,
buffer: &[u8],
cancellable: Option<&P>
) -> Result<isize, Error> where
P: IsA<Cancellable>,
&self,
buffer: &[u8],
cancellable: Option<&P>
) -> Result<isize, Error> where
P: IsA<Cancellable>,
pub fn write_bytes<P>(
&self,
bytes: &Bytes,
cancellable: Option<&P>
) -> Result<isize, Error> where
P: IsA<Cancellable>,
&self,
bytes: &Bytes,
cancellable: Option<&P>
) -> Result<isize, Error> where
P: IsA<Cancellable>,
pub fn write_bytes_async<P, Q>(
&self,
bytes: &Bytes,
io_priority: Priority,
cancellable: Option<&P>,
callback: Q
) where
P: IsA<Cancellable>,
Q: 'static + FnOnce(Result<isize, Error>) + Send,
&self,
bytes: &Bytes,
io_priority: Priority,
cancellable: Option<&P>,
callback: Q
) where
P: IsA<Cancellable>,
Q: 'static + FnOnce(Result<isize, Error>) + Send,
pub fn write_bytes_async_future(
&self,
bytes: &Bytes,
io_priority: Priority
) -> Pin<Box<dyn Future<Output = Result<isize, Error>> + 'static, Global>>
&self,
bytes: &Bytes,
io_priority: Priority
) -> Pin<Box<dyn Future<Output = Result<isize, Error>> + 'static, Global>>