pub struct HttpResponse {
pub status: Nat,
pub headers: Vec<HttpHeader>,
pub body: Vec<u8>,
}๐Deprecated since 0.18.0: The
api::management_canister::http_request module is deprecated. Please use the management_canister module at the crate root.Expand description
The returned HTTP response.
Fieldsยง
ยงstatus: Nat๐Deprecated since 0.18.0: The
api::management_canister::http_request module is deprecated. Please use the management_canister module at the crate root.The response status (e.g., 200, 404).
headers: Vec<HttpHeader>๐Deprecated since 0.18.0: The
api::management_canister::http_request module is deprecated. Please use the management_canister module at the crate root.List of HTTP response headers and their corresponding values.
body: Vec<u8>๐Deprecated since 0.18.0: The
api::management_canister::http_request module is deprecated. Please use the management_canister module at the crate root.The responseโs body.
Trait Implementationsยง
Sourceยงimpl CandidType for HttpResponse
impl CandidType for HttpResponse
Sourceยงimpl Clone for HttpResponse
impl Clone for HttpResponse
Sourceยงfn clone(&self) -> HttpResponse
fn clone(&self) -> HttpResponse
Returns a copy of the value. Read more
1.0.0 ยท Sourceยงfn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSourceยงimpl Debug for HttpResponse
impl Debug for HttpResponse
Sourceยงimpl Default for HttpResponse
impl Default for HttpResponse
Sourceยงfn default() -> HttpResponse
fn default() -> HttpResponse
Returns the โdefault valueโ for a type. Read more
Sourceยงimpl<'de> Deserialize<'de> for HttpResponse
impl<'de> Deserialize<'de> for HttpResponse
Sourceยงfn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Sourceยงimpl Hash for HttpResponse
impl Hash for HttpResponse
Sourceยงimpl Ord for HttpResponse
impl Ord for HttpResponse
Sourceยงfn cmp(&self, other: &HttpResponse) -> Ordering
fn cmp(&self, other: &HttpResponse) -> Ordering
1.21.0 ยท Sourceยงfn max(self, other: Self) -> Selfwhere
Self: Sized,
fn max(self, other: Self) -> Selfwhere
Self: Sized,
Compares and returns the maximum of two values. Read more
Sourceยงimpl PartialEq for HttpResponse
impl PartialEq for HttpResponse
Sourceยงimpl PartialOrd for HttpResponse
impl PartialOrd for HttpResponse
Sourceยงimpl Serialize for HttpResponse
impl Serialize for HttpResponse
impl Eq for HttpResponse
impl StructuralPartialEq for HttpResponse
Auto Trait Implementationsยง
impl Freeze for HttpResponse
impl RefUnwindSafe for HttpResponse
impl Send for HttpResponse
impl Sync for HttpResponse
impl Unpin for HttpResponse
impl UnwindSafe 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