pub struct AdminKernelResponse {
pub request_id: Option<String>,
pub body: AdminResponseBody,
}Expand description
Admin management API response wrapper carrying the echoed correlation ID and the typed response body.
Fields§
§request_id: Option<String>Echoed request_id from the AdminKernelRequest this response
answers. None when the client did not provide one.
body: AdminResponseBodyThe typed response body — tag = "status", content = "data".
Implementations§
Source§impl AdminKernelResponse
impl AdminKernelResponse
Sourcepub const fn new(body: AdminResponseBody) -> Self
pub const fn new(body: AdminResponseBody) -> Self
Build a response with the given body and no correlation ID.
Sourcepub fn for_request(request_id: Option<String>, body: AdminResponseBody) -> Self
pub fn for_request(request_id: Option<String>, body: AdminResponseBody) -> Self
Build a response that echoes a request’s correlation ID.
Trait Implementations§
Source§impl Clone for AdminKernelResponse
impl Clone for AdminKernelResponse
Source§fn clone(&self) -> AdminKernelResponse
fn clone(&self) -> AdminKernelResponse
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · 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 AdminKernelResponse
impl Debug for AdminKernelResponse
Source§impl<'de> Deserialize<'de> for AdminKernelResponse
impl<'de> Deserialize<'de> for AdminKernelResponse
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
Auto Trait Implementations§
impl Freeze for AdminKernelResponse
impl RefUnwindSafe for AdminKernelResponse
impl Send for AdminKernelResponse
impl Sync for AdminKernelResponse
impl Unpin for AdminKernelResponse
impl UnsafeUnpin for AdminKernelResponse
impl UnwindSafe for AdminKernelResponse
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