[][src]Struct actix::io::SinkWrite

pub struct SinkWrite<S: Sink> { /* fields omitted */ }

A wrapper for the Sink type.

Methods

impl<S: Sink + 'static> SinkWrite<S>[src]

pub fn new<A, C>(sink: S, ctxt: &mut C) -> Self where
    A: Actor<Context = C> + WriteHandler<S::SinkError>,
    C: AsyncContext<A>, 
[src]

pub fn write(
    &mut self,
    item: S::SinkItem
) -> StartSend<S::SinkItem, S::SinkError>
[src]

Sends an item to the sink.

pub fn close(&mut self)[src]

Gracefully closes the sink.

The closing happens asynchronously.

pub fn closed(&self) -> bool[src]

Checks if the sink is closed.

pub fn handle(&self) -> SpawnHandle[src]

Returns the SpawnHandle for this writer.

Auto Trait Implementations

impl<S> !Send for SinkWrite<S>

impl<S> !Sync for SinkWrite<S>

Blanket Implementations

impl<T> From for T[src]

impl<T, U> Into for T where
    U: From<T>, 
[src]

impl<T, U> TryFrom for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T> Borrow for T where
    T: ?Sized
[src]

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<T> BorrowMut for T where
    T: ?Sized
[src]

impl<T, U> TryInto for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.

impl<T> Erased for T