pub struct Bus { /* private fields */ }Implementations§
Source§impl Bus
impl Bus
pub fn new() -> Self
pub async fn register<M: Message, B: Builder<M>>(&self, builder: B) -> &Self
pub async fn register_mapper<M: Message, R: Message, E: ErrorMessage, C: Send + Clone + Sync + FnMut(u32, u32, M) -> Result<R, E> + 'static>( &self, cb: C, ) -> &Self
pub async fn send<M: Message>(&self, inner: M) -> Result<(), Error>
pub async fn send_with_stream<M: Message>( &self, stream_id: u32, inner: M, ) -> Result<(), Error>
Trait Implementations§
Auto Trait Implementations§
impl Freeze for Bus
impl !RefUnwindSafe for Bus
impl Send for Bus
impl Sync for Bus
impl Unpin for Bus
impl !UnwindSafe for Bus
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more