mod error;
pub mod parallel;
pub mod prelude;
pub mod serial;
mod shared;
pub use self::error::{SendError, TryRecvError, TrySendError};
pub trait Sender<T> {
fn send(&mut self, value: T) -> Result<(), SendError<T>>;
fn try_send(&mut self, value: T) -> Result<(), TrySendError<T>>;
fn close(&mut self);
fn is_closed(&self) -> bool;
}
pub trait Receiver<T> {
fn recv(&mut self) -> Option<T>;
fn try_recv(&mut self) -> Result<T, TryRecvError>;
fn close(&mut self);
fn terminate(&mut self);
fn is_drained(&self) -> bool;
}