pub struct NoBody<T>(pub T);Expand description
A content type for responses that have no body. Mostly used for generic HTTP Errors
Tuple Fields§
§0: TTrait Implementations§
Source§impl<T: RestResponse> ContentType<T> for NoBody<T>
impl<T: RestResponse> ContentType<T> for NoBody<T>
const CONTENT_TYPE: &'static str = "none"
Source§impl<T> Deserialize for NoBody<T>
impl<T> Deserialize for NoBody<T>
async fn deserialize<'a, 'b>( _: &'a mut DeserializeStream<'b>, _: usize, ) -> Result<Self, Box<dyn Error>>
Auto Trait Implementations§
impl<T> Freeze for NoBody<T>where
T: Freeze,
impl<T> RefUnwindSafe for NoBody<T>where
T: RefUnwindSafe,
impl<T> Send for NoBody<T>where
T: Send,
impl<T> Sync for NoBody<T>where
T: Sync,
impl<T> Unpin for NoBody<T>where
T: Unpin,
impl<T> UnsafeUnpin for NoBody<T>where
T: UnsafeUnpin,
impl<T> UnwindSafe for NoBody<T>where
T: UnwindSafe,
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