pub enum Body {
InMemory(InMemoryBody),
Incoming(Incoming),
}Variants§
InMemory(InMemoryBody)
Incoming(Incoming)
Implementations§
Source§impl Body
impl Body
pub fn is_empty(&self) -> bool
pub async fn into_memory(self) -> ProtocolResult<InMemoryBody>
pub async fn into_content_type( self, content_type: Option<&HeaderValue>, ) -> ProtocolResult<InMemoryBody>
Trait Implementations§
Source§impl From<InMemoryBody> for Body
impl From<InMemoryBody> for Body
Source§fn from(value: InMemoryBody) -> Self
fn from(value: InMemoryBody) -> Self
Converts to this type from the input type.
Auto Trait Implementations§
impl Freeze for Body
impl !RefUnwindSafe for Body
impl Send for Body
impl Sync for Body
impl Unpin for Body
impl !UnwindSafe for Body
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