Struct futures::sink::Close
[−]
[src]
#[must_use = "futures do nothing unless polled"]pub struct Close<S> { /* fields omitted */ }
Future for the close
combinator, which polls the sink until all data has
been closeed.
Methods
impl<S> Close<S> where
S: Sink,
[src]
S: Sink,
pub fn get_ref(&self) -> Option<&S>
[src]
Get a shared reference to the inner sink.
Returns None
if the sink has already been closeed.
pub fn get_mut(&mut self) -> Option<&mut S>
[src]
Get a mutable reference to the inner sink.
Returns None
if the sink has already been closeed.
pub fn into_inner(self) -> Option<S>
[src]
Consume the Close
and return the inner sink.
Returns None
if the sink has already been closeed.
Trait Implementations
impl<S> Future for Close<S> where
S: Sink,
[src]
S: Sink,
type Item = S
A successful value
type Error = <S as Sink>::SinkError
An error
fn poll(&mut self, cx: &mut Context) -> Result<Async<S>, <S as Sink>::SinkError>
[src]
Attempt to resolve the future to a final value, registering the current task for wakeup if the value is not yet available. Read more
impl<S> Debug for Close<S> where
S: Debug,
[src]
S: Debug,