pub enum ResponseBody {
Empty,
Full(Bytes),
Stream(BoxBodyStream),
}Expand description
Represents the body of an HTTP response.
Variants§
Empty
No body content is present.
Full(Bytes)
Entire payload is buffered in memory.
Stream(BoxBodyStream)
Payload will be produced lazily via chunked transfer encoding.
Implementations§
Trait Implementations§
Auto Trait Implementations§
impl !Freeze for ResponseBody
impl !RefUnwindSafe for ResponseBody
impl !Sync for ResponseBody
impl !UnwindSafe for ResponseBody
impl Send for ResponseBody
impl Unpin for ResponseBody
impl UnsafeUnpin for ResponseBody
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