[][src]Trait lifeline::Bus

pub trait Bus: Default + Debug + Sized {
    fn capacity<Msg>(&self, capacity: usize) -> Result<(), AlreadyLinkedError>
    where
        Msg: Message<Self> + 'static
;
fn rx<Msg>(
        &self
    ) -> Result<LifelineReceiver<Msg, <Msg::Channel as Channel>::Rx>, TakeChannelError>
    where
        Msg: Message<Self> + 'static
;
fn tx<Msg>(
        &self
    ) -> Result<LifelineSender<Msg, <Msg::Channel as Channel>::Tx>, TakeChannelError>
    where
        Msg: Message<Self> + 'static
;
fn resource<Res>(&self) -> Result<Res, TakeResourceError>
    where
        Res: Resource<Self>
; }

The bus carries

Required methods

fn capacity<Msg>(&self, capacity: usize) -> Result<(), AlreadyLinkedError> where
    Msg: Message<Self> + 'static, 

Returns the receiver on the first call, and

fn rx<Msg>(
    &self
) -> Result<LifelineReceiver<Msg, <Msg::Channel as Channel>::Rx>, TakeChannelError> where
    Msg: Message<Self> + 'static, 

fn tx<Msg>(
    &self
) -> Result<LifelineSender<Msg, <Msg::Channel as Channel>::Tx>, TakeChannelError> where
    Msg: Message<Self> + 'static, 

fn resource<Res>(&self) -> Result<Res, TakeResourceError> where
    Res: Resource<Self>, 

Loading content...

Implementors

impl<T> Bus for T where
    T: DynBus
[src]

Loading content...