pub struct ResponseMeta { /* private fields */ }Expand description
The HTTP side of a successful response.
The body is the exact bytes the server sent, kept as a reference-counted buffer rather than a copy. It is the way back to anything the decoder left out, such as an answer of a type this version does not know.
Debug prints the header count and the body length, not their contents: a
response header may carry a cookie, and the body is the caller’s to log.
Implementations§
Source§impl ResponseMeta
impl ResponseMeta
Sourcepub fn status(&self) -> StatusCode
pub fn status(&self) -> StatusCode
The HTTP status, which is always a success status here.
Sourcepub fn request_id(&self) -> Option<&str>
pub fn request_id(&self) -> Option<&str>
The server’s identifier for the request, from the
x-typesafe-request-id header, when the server sent one that is valid
text.
Trait Implementations§
Source§impl Clone for ResponseMeta
impl Clone for ResponseMeta
Source§impl Debug for ResponseMeta
impl Debug for ResponseMeta
Source§impl PartialEq for ResponseMeta
impl PartialEq for ResponseMeta
impl StructuralPartialEq for ResponseMeta
Auto Trait Implementations§
impl !Freeze for ResponseMeta
impl RefUnwindSafe for ResponseMeta
impl Send for ResponseMeta
impl Sync for ResponseMeta
impl Unpin for ResponseMeta
impl UnsafeUnpin for ResponseMeta
impl UnwindSafe for ResponseMeta
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