pub struct HttpResponse {
pub status: u16,
pub content_type: Option<String>,
pub body: Box<dyn Read + Send>,
}Expand description
A buffered HTTP response whose body streams directly from the network.
Note that any HTTP status (including 4xx/5xx) is reported here with a
populated status; transport-level failures are
reported as Err from the HttpClient methods instead.
Fields§
§status: u16§content_type: Option<String>§body: Box<dyn Read + Send>Auto Trait Implementations§
impl !RefUnwindSafe for HttpResponse
impl !Sync for HttpResponse
impl !UnwindSafe for HttpResponse
impl Freeze for HttpResponse
impl Send for HttpResponse
impl Unpin for HttpResponse
impl UnsafeUnpin for HttpResponse
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