pub struct Extract<T>(pub T);Expand description
Explicitly asks the operation macro to extract T from the invocation.
Bare handler argument types remain compiled dependency-injection requests;
wrapping a downstream FromInvocation implementation in Extract<T>
removes that ambiguity without teaching the macro about every application’s
extractor type. The wrapper delegates extraction verbatim, including a
custom extractor’s transport-specific rejection.
Tuple Fields§
§0: TTrait Implementations§
impl<T: Copy> Copy for Extract<T>
impl<T: Eq> Eq for Extract<T>
Source§impl<T: FromInvocation> FromInvocation for Extract<T>
impl<T: FromInvocation> FromInvocation for Extract<T>
Source§fn from_invocation(
input: &InvocationInput<'_>,
name: &str,
required: bool,
) -> Result<Self, InputRejection>
fn from_invocation( input: &InvocationInput<'_>, name: &str, required: bool, ) -> Result<Self, InputRejection>
Extracts one handler argument. Read more
impl<T: PartialEq> StructuralPartialEq for Extract<T>
Auto Trait Implementations§
impl<T> Freeze for Extract<T>where
T: Freeze,
impl<T> RefUnwindSafe for Extract<T>where
T: RefUnwindSafe,
impl<T> Send for Extract<T>where
T: Send,
impl<T> Sync for Extract<T>where
T: Sync,
impl<T> Unpin for Extract<T>where
T: Unpin,
impl<T> UnsafeUnpin for Extract<T>where
T: UnsafeUnpin,
impl<T> UnwindSafe for Extract<T>where
T: UnwindSafe,
Blanket Implementations§
Source§impl<T> BackgroundExt for T
impl<T> BackgroundExt for T
fn background(self, task: BackgroundTask) -> Background<Self>
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