pub struct Response {
pub http_status: StatusCode,
pub code: u32,
pub data: Option<Value>,
pub message: Option<Cow<'static, str>>,
pub timestamp: DateTime,
pub request_id: Option<String>,
pub correlation_id: Option<String>,
}Expand description
An Ocpi Response structure.
Fields§
§http_status: StatusCode§code: u32§data: Option<Value>§message: Option<Cow<'static, str>>§timestamp: DateTime§request_id: Option<String>§correlation_id: Option<String>Implementations§
Trait Implementations§
Source§impl<T> From<ContextResult<T>> for Responsewhere
T: Serialize,
impl<T> From<ContextResult<T>> for Responsewhere
T: Serialize,
Source§fn from(_: ContextResult<T>) -> Self
fn from(_: ContextResult<T>) -> Self
Converts to this type from the input type.
Auto Trait Implementations§
impl Freeze for Response
impl RefUnwindSafe for Response
impl Send for Response
impl Sync for Response
impl Unpin for Response
impl UnwindSafe for Response
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