Trait busrt::client::AsyncClient

source ·
pub trait AsyncClient: Send + Sync {
Show 14 methods // Required methods fn take_event_channel(&mut self) -> Option<Receiver<Frame>>; fn send<'life0, 'life1, 'async_trait>( &'life0 mut self, target: &'life1 str, payload: Cow<'async_trait>, qos: QoS ) -> Pin<Box<dyn Future<Output = Result<OpConfirm, Error>> + Send + 'async_trait>> where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait; fn zc_send<'life0, 'life1, 'async_trait>( &'life0 mut self, target: &'life1 str, header: Cow<'async_trait>, payload: Cow<'async_trait>, qos: QoS ) -> Pin<Box<dyn Future<Output = Result<OpConfirm, Error>> + Send + 'async_trait>> where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait; fn send_broadcast<'life0, 'life1, 'async_trait>( &'life0 mut self, target: &'life1 str, payload: Cow<'async_trait>, qos: QoS ) -> Pin<Box<dyn Future<Output = Result<OpConfirm, Error>> + Send + 'async_trait>> where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait; fn publish<'life0, 'life1, 'async_trait>( &'life0 mut self, target: &'life1 str, payload: Cow<'async_trait>, qos: QoS ) -> Pin<Box<dyn Future<Output = Result<OpConfirm, Error>> + Send + 'async_trait>> where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait; fn subscribe<'life0, 'life1, 'async_trait>( &'life0 mut self, topic: &'life1 str, qos: QoS ) -> Pin<Box<dyn Future<Output = Result<OpConfirm, Error>> + Send + 'async_trait>> where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait; fn unsubscribe<'life0, 'life1, 'async_trait>( &'life0 mut self, topic: &'life1 str, qos: QoS ) -> Pin<Box<dyn Future<Output = Result<OpConfirm, Error>> + Send + 'async_trait>> where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait; fn subscribe_bulk<'life0, 'life1, 'life2, 'async_trait>( &'life0 mut self, topics: &'life1 [&'life2 str], qos: QoS ) -> Pin<Box<dyn Future<Output = Result<OpConfirm, Error>> + Send + 'async_trait>> where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait, 'life2: 'async_trait; fn unsubscribe_bulk<'life0, 'life1, 'life2, 'async_trait>( &'life0 mut self, topics: &'life1 [&'life2 str], qos: QoS ) -> Pin<Box<dyn Future<Output = Result<OpConfirm, Error>> + Send + 'async_trait>> where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait, 'life2: 'async_trait; fn ping<'life0, 'async_trait>( &'life0 mut self ) -> Pin<Box<dyn Future<Output = Result<(), Error>> + Send + 'async_trait>> where Self: 'async_trait, 'life0: 'async_trait; fn is_connected(&self) -> bool; fn get_connected_beacon(&self) -> Option<Arc<AtomicBool>>; fn get_timeout(&self) -> Option<Duration>; fn get_name(&self) -> &str;
}

Required Methods§

source

fn take_event_channel(&mut self) -> Option<Receiver<Frame>>

source

fn send<'life0, 'life1, 'async_trait>( &'life0 mut self, target: &'life1 str, payload: Cow<'async_trait>, qos: QoS ) -> Pin<Box<dyn Future<Output = Result<OpConfirm, Error>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait,

source

fn zc_send<'life0, 'life1, 'async_trait>( &'life0 mut self, target: &'life1 str, header: Cow<'async_trait>, payload: Cow<'async_trait>, qos: QoS ) -> Pin<Box<dyn Future<Output = Result<OpConfirm, Error>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait,

source

fn send_broadcast<'life0, 'life1, 'async_trait>( &'life0 mut self, target: &'life1 str, payload: Cow<'async_trait>, qos: QoS ) -> Pin<Box<dyn Future<Output = Result<OpConfirm, Error>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait,

source

fn publish<'life0, 'life1, 'async_trait>( &'life0 mut self, target: &'life1 str, payload: Cow<'async_trait>, qos: QoS ) -> Pin<Box<dyn Future<Output = Result<OpConfirm, Error>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait,

source

fn subscribe<'life0, 'life1, 'async_trait>( &'life0 mut self, topic: &'life1 str, qos: QoS ) -> Pin<Box<dyn Future<Output = Result<OpConfirm, Error>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait,

source

fn unsubscribe<'life0, 'life1, 'async_trait>( &'life0 mut self, topic: &'life1 str, qos: QoS ) -> Pin<Box<dyn Future<Output = Result<OpConfirm, Error>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait,

source

fn subscribe_bulk<'life0, 'life1, 'life2, 'async_trait>( &'life0 mut self, topics: &'life1 [&'life2 str], qos: QoS ) -> Pin<Box<dyn Future<Output = Result<OpConfirm, Error>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait, 'life2: 'async_trait,

source

fn unsubscribe_bulk<'life0, 'life1, 'life2, 'async_trait>( &'life0 mut self, topics: &'life1 [&'life2 str], qos: QoS ) -> Pin<Box<dyn Future<Output = Result<OpConfirm, Error>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait, 'life2: 'async_trait,

source

fn ping<'life0, 'async_trait>( &'life0 mut self ) -> Pin<Box<dyn Future<Output = Result<(), Error>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

source

fn is_connected(&self) -> bool

source

fn get_connected_beacon(&self) -> Option<Arc<AtomicBool>>

source

fn get_timeout(&self) -> Option<Duration>

source

fn get_name(&self) -> &str

Implementors§

source§

impl AsyncClient for busrt::broker::Client

source§

impl AsyncClient for busrt::ipc::Client