WithRoute

Struct WithRoute 

Source
pub struct WithRoute<'a, T: ?Sized, Route> { /* private fields */ }
Expand description

Sink for RouteSink and a specific route.

Trait Implementations§

Source§

impl<'a, T: Debug + ?Sized, Route: Debug> Debug for WithRoute<'a, T, Route>

Source§

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

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

impl<Route: Clone, Msg, E, T: ?Sized + RouteSink<Route, Msg, Error = E>> Sink<Msg> for WithRoute<'_, T, Route>

Source§

type Error = E

The type of value produced by the sink when an error occurs.
Source§

fn poll_ready( self: Pin<&mut Self>, cx: &mut Context<'_>, ) -> Poll<Result<(), Self::Error>>

Attempts to prepare the Sink to receive a value. Read more
Source§

fn start_send(self: Pin<&mut Self>, msg: Msg) -> Result<(), Self::Error>

Begin the process of sending a value to the sink. Each call to this function must be preceded by a successful call to poll_ready which returned Poll::Ready(Ok(())). Read more
Source§

fn poll_flush( self: Pin<&mut Self>, cx: &mut Context<'_>, ) -> Poll<Result<(), Self::Error>>

Flush any remaining output from this sink. Read more
Source§

fn poll_close( self: Pin<&mut Self>, cx: &mut Context<'_>, ) -> Poll<Result<(), Self::Error>>

Flush any remaining output and close this sink, if necessary. Read more
Source§

impl<T: ?Sized, Route> Unpin for WithRoute<'_, T, Route>

Auto Trait Implementations§

§

impl<'a, T, Route> Freeze for WithRoute<'a, T, Route>
where Route: Freeze, T: ?Sized,

§

impl<'a, T, Route> RefUnwindSafe for WithRoute<'a, T, Route>
where Route: RefUnwindSafe, T: RefUnwindSafe + ?Sized,

§

impl<'a, T, Route> Send for WithRoute<'a, T, Route>
where Route: Send, T: Send + ?Sized,

§

impl<'a, T, Route> Sync for WithRoute<'a, T, Route>
where Route: Sync, T: Sync + ?Sized,

§

impl<'a, T, Route> !UnwindSafe for WithRoute<'a, T, Route>

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> 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<Route, Msg, E, T> RouteSink<Route, Msg> for T
where T: Sink<(Route, Msg), Error = E> + ?Sized,

Source§

type Error = E

The type of value produced by the sink when an error occurs. Read more
Source§

fn poll_ready( self: Pin<&mut T>, _: &Route, cx: &mut Context<'_>, ) -> Poll<Result<(), <T as RouteSink<Route, Msg>>::Error>>

Attempts to prepare the RouteSink to receive a message on a specified route. Read more
Source§

fn poll_ready_any( self: Pin<&mut T>, cx: &mut Context<'_>, ) -> Poll<Result<(), <T as RouteSink<Route, Msg>>::Error>>

Attempt to prepare the RouteSink to receive a message on an arbitrary route. Read more
Source§

fn start_send( self: Pin<&mut T>, route: Route, msg: Msg, ) -> Result<(), <T as RouteSink<Route, Msg>>::Error>

Begin the process of sending a message to the RouteSink on a specified route. Read more
Source§

fn poll_flush( self: Pin<&mut T>, _: &Route, cx: &mut Context<'_>, ) -> Poll<Result<(), <T as RouteSink<Route, Msg>>::Error>>

Flush all the remaining items on a specified route. Read more
Source§

fn poll_flush_all( self: Pin<&mut T>, cx: &mut Context<'_>, ) -> Poll<Result<(), <T as RouteSink<Route, Msg>>::Error>>

Flush all the routes. Read more
Source§

fn poll_close( self: Pin<&mut T>, cx: &mut Context<'_>, ) -> Poll<Result<(), <T as RouteSink<Route, Msg>>::Error>>

Flush and close all the routes. Read more
Source§

fn is_routing(&self) -> bool

Whether this RouteSink itself is doing any actual routing and keeping wakers separate. 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.