[][src]Trait cerk::runtime::channel::Receiver

pub trait Receiver: Send {
    pub fn receive(&self) -> BrokerEvent;
pub fn receive_timeout(&self, timeout: Duration) -> Option<BrokerEvent>; }

Wrapper for a platform-specific channel receiver.

Required methods

pub fn receive(&self) -> BrokerEvent[src]

Messages sent to the channel can be retrieved using this function. The call is blocking.

pub fn receive_timeout(&self, timeout: Duration) -> Option<BrokerEvent>[src]

Messages sent to the channel can be retrieved using this function. The call is blocking for a given duration.

Arguments

  • timeout - The maximum time to block the caller and wait for a message.
Loading content...

Implementors

Loading content...