Enum rocket::response::Body [−][src]
Expand description
The body of a response: can be sized or streamed/chunked.
Variants
Sized(T, u64)A fixed-size body.
Tuple Fields of Sized
0: T1: u64Chunked(T, u64)A streamed/chunked body, akin to Transfer-Encoding: chunked.
Tuple Fields of Chunked
0: T1: u64Implementations
Returns a new Body with a mutable borrow to self’s inner type.
Consumes self. Passes the inner type as a parameter to f and
constructs a new body with the size of self and the return value of
the call to f.
Consumes self and returns the inner body.
Returns true if self is a Body::Chunked.
Attempts to read self into a Vec and returns it. If reading fails,
returns None.
Attempts to read self into a String and returns it. If reading or
conversion fails, returns None.
Trait Implementations
Auto Trait Implementations
impl<T> RefUnwindSafe for Body<T> where
T: RefUnwindSafe,
impl<T> UnwindSafe for Body<T> where
T: UnwindSafe,
Blanket Implementations
Mutably borrows from an owned value. Read more