pub struct StateRef<'a, S>(pub &'a S)
where
S: ?Sized;Expand description
App state extractor. S type must be the same with the type passed to App::with_xxx_state(S).
Tuple Fields§
§0: &'a STrait Implementations§
source§impl<'a, 'r, C, B, T> FromRequest<'a, WebContext<'r, C, B>> for StateRef<'a, T>
impl<'a, 'r, C, B, T> FromRequest<'a, WebContext<'r, C, B>> for StateRef<'a, T>
Auto Trait Implementations§
impl<'a, S: ?Sized> RefUnwindSafe for StateRef<'a, S>where
S: RefUnwindSafe,
impl<'a, S: ?Sized> Send for StateRef<'a, S>where
S: Sync,
impl<'a, S: ?Sized> Sync for StateRef<'a, S>where
S: Sync,
impl<'a, S: ?Sized> Unpin for StateRef<'a, S>
impl<'a, S: ?Sized> UnwindSafe for StateRef<'a, S>where
S: RefUnwindSafe,
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