pub struct Answer<T> {
pub value: T,
pub raw: Value,
pub etag: Option<String>,
}Expand description
A parsed answer, and the body it was parsed from.
Both halves are kept because both are used: raw is what a tool hands
back, so the caller sees whatever the control plane sent rather than the
subset this build knows the names of, and value is what the server reads
when it has to act on the answer.
Fields§
§value: T§raw: ValueThe body, parsed as JSON and otherwise untouched.
etag: Option<String>The ETag header, for the endpoints that version their document.
Trait Implementations§
Auto Trait Implementations§
impl<T> Freeze for Answer<T>where
T: Freeze,
impl<T> RefUnwindSafe for Answer<T>where
T: RefUnwindSafe,
impl<T> Send for Answer<T>where
T: Send,
impl<T> Sync for Answer<T>where
T: Sync,
impl<T> Unpin for Answer<T>where
T: Unpin,
impl<T> UnsafeUnpin for Answer<T>where
T: UnsafeUnpin,
impl<T> UnwindSafe for Answer<T>where
T: UnwindSafe,
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