Struct WebsocketListenerBus

Source
pub struct WebsocketListenerBus { /* private fields */ }

Trait Implementations§

Source§

impl Debug for WebsocketListenerBus

Source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
Source§

impl Default for WebsocketListenerBus

Source§

fn default() -> Self

Returns the “default value” for a type. Read more
Source§

impl DynBus for WebsocketListenerBus

Source§

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

Stores an manually constructed Receiver on the bus, for the provided message type. Read more
Source§

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

Stores an manually constructed Sender on the bus, for the provided message type. Read more
Source§

fn store_channel<Msg>( &self, rx: <Msg::Channel as Channel>::Rx, tx: <Msg::Channel as Channel>::Tx, ) -> Result<(), AlreadyLinkedError>
where Msg: Message<Self> + 'static,

Stores a channel pair on the bus, for the provided message type. Read more
Source§

fn store_resource<R: Resource<Self>>(&self, resource: R)

Stores a resource on the bus. Read more
Source§

fn storage(&self) -> &DynBusStorage<Self>

Returns the DynBusStorage struct which manages the trait object slots.
Source§

impl Message<WebsocketListenerBus> for WebsocketConnectionMessage

Source§

impl Resource<WebsocketListenerBus> for WebsocketAuthToken

Source§

impl Resource<WebsocketListenerBus> for WebsocketListenerResource

Auto Trait Implementations§

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<T> Bus for T
where T: DynBus,

Source§

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

Takes (or clones) the channel Receiver. The message type must implement Message<Bus>, which defines the channel type. Read more
Source§

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

Takes (or clones) the channel Sender. The message type must implement Message<Bus>, which defines the channel type. Read more
Source§

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

Configures the channel capacity, if the linked channel implementation takes a capacity during initialization Read more
Source§

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

Takes (or clones) the Resource. Read more
Source§

impl<F, I> CarryInto<I> for F
where I: CarryFrom<F> + Bus, F: Bus,

Source§

type Lifeline = <I as CarryFrom<F>>::Lifeline

The carrier lifeline. When dropped, all spawned tasks are immediately cancelled.
Source§

fn carry_into(&self, into: &I) -> <F as CarryInto<I>>::Lifeline

Spawns the carrier service, returning the lifeline value.
Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<T> Same for T

Source§

type Output = T

Should always be Self
Source§

impl<T> Task for T

Source§

fn task<Out>( name: &str, fut: impl Future<Output = Out> + Send + 'static, ) -> Lifeline
where Out: Debug + Send + 'static, Self: Sized,

Spawns an infallible task using the provided executor, wrapping it in a Lifeline handle. The task will run until it finishes, or until the Lifeline is droped.
Source§

fn try_task<Out>( name: &str, fut: impl Future<Output = Result<Out, Error>> + Send + 'static, ) -> Lifeline
where Out: Debug + 'static, Self: Sized,

Spawns an fallible task using the provided executor, wrapping it in a Lifeline handle. The task will run until it finishes, or until the Lifeline is droped. Read more
Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = Infallible

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.
Source§

impl<V, T> VZip<V> for T
where V: MultiLane<T>,

Source§

fn vzip(self) -> V

Source§

impl<T> ErasedDestructor for T
where T: 'static,