pub struct ToService<'a> { /* private fields */ }Expand description
A routing decision produced by Endpoint::handle().
Implementations§
Source§impl<'a> ToService<'a>
impl<'a> ToService<'a>
Sourcepub const fn handle(&self) -> ServiceHandle
pub const fn handle(&self) -> ServiceHandle
Returns the service handle this event is addressed to.
Sourcepub const fn event(&self) -> &ServiceEvent<'a>
pub const fn event(&self) -> &ServiceEvent<'a>
Returns a reference to the service event payload.
Sourcepub const fn into_event(self) -> ServiceEvent<'a>
pub const fn into_event(self) -> ServiceEvent<'a>
Consumes the routing decision and returns the inner event.
Trait Implementations§
Auto Trait Implementations§
impl<'a> Freeze for ToService<'a>
impl<'a> RefUnwindSafe for ToService<'a>
impl<'a> Send for ToService<'a>
impl<'a> Sync for ToService<'a>
impl<'a> Unpin for ToService<'a>
impl<'a> UnsafeUnpin for ToService<'a>
impl<'a> UnwindSafe for ToService<'a>
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