Struct cqrs_es2::UserErrorPayload [−][src]
pub struct UserErrorPayload { pub code: Option<String>, pub message: Option<String>, pub params: Option<HashMap<String, String>>, }
Expand description
Payload for an AggregateError::UserError
, somewhat modeled on
the errors produced by the validator
package. This payload implements Serialize
with the intention of allowing the user to return this object as
the response payload.
Fields
code: Option<String>
An optional code to indicate the a user-defined error.
message: Option<String>
An optional message describing the error, meant to be returned to the user.
params: Option<HashMap<String, String>>
Optional additional parameters for adding additional context to the error.
Trait Implementations
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
This method tests for self
and other
values to be equal, and is used
by ==
. Read more
This method tests for !=
.