Struct extra::comm::DuplexStream

pub struct DuplexStream<T, U> {
    priv chan: std::comm::Chan,
    priv port: std::comm::Port,
}

An extension of pipes::stream that allows both sending and receiving.

Methods

impl<T: std::kinds::Send, U: std::kinds::Send> DuplexStream<T, U>

fn send(&self, x: T)

fn try_send(&self, x: T) -> bool

fn recv(&self) -> U

fn try_recv(&self) -> std::option::Option

fn peek(&self) -> bool

Trait Implementations

impl<T: std::kinds::Send, U: std::kinds::Send> std::comm::GenericChan for DuplexStream<T, U>

fn send(&self, x: T)

impl<T: std::kinds::Send, U: std::kinds::Send> std::comm::GenericSmartChan for DuplexStream<T, U>

fn try_send(&self, x: T) -> bool

impl<T: std::kinds::Send, U: std::kinds::Send> std::comm::GenericPort for DuplexStream<T, U>

fn recv(&self) -> U

fn try_recv(&self) -> std::option::Option

impl<T: std::kinds::Send, U: std::kinds::Send> std::comm::Peekable for DuplexStream<T, U>

fn peek(&self) -> bool