#[non_exhaustive]pub enum InteractionError {
Rejected(InteractionRejection),
InvalidTransition {
interaction_id: InteractionId,
from: InteractionStatus,
to: InteractionStatus,
},
BlockingConflict {
existing: InteractionId,
},
PayloadHashMismatch {
interaction_id: InteractionId,
},
NotPersisted,
InvalidSpec(InteractionSpecError),
InvalidTtl,
Hash,
}Expand description
Interaction lifecycle errors (spec §15).
The wire form is adjacently tagged ({"kind": ..., "detail": ...}): several
variants wrap another tagged error, and an internal tag would write two
kind keys into one object, so the outer variant was lost on the way back.
Variants (Non-exhaustive)§
This enum is marked as non-exhaustive
Rejected(InteractionRejection)
A client response was rejected by crate::interaction::validate_response.
InvalidTransition
An illegal status transition was attempted.
Fields
interaction_id: InteractionIdThe interaction.
from: InteractionStatusCurrent status.
to: InteractionStatusRequested status.
BlockingConflict
A second active blocking interaction was requested for the same case (I5).
Fields
existing: InteractionIdThe interaction already active.
PayloadHashMismatch
The stored payload hash does not match the payload.
Fields
interaction_id: InteractionIdThe interaction.
NotPersisted
The interaction must be persisted before it can be referenced.
InvalidSpec(InteractionSpecError)
The card was refused before it could be created.
InvalidTtl
The time to live cannot be applied to the creation instant.
Hash
The payload could not be hashed.
Trait Implementations§
Source§impl Clone for InteractionError
impl Clone for InteractionError
Source§impl Debug for InteractionError
impl Debug for InteractionError
Source§impl<'de> Deserialize<'de> for InteractionError
impl<'de> Deserialize<'de> for InteractionError
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>,
Source§impl Display for InteractionError
impl Display for InteractionError
impl Eq for InteractionError
Source§impl Error for InteractionError
impl Error for InteractionError
Source§fn source(&self) -> Option<&(dyn Error + 'static)>
fn source(&self) -> Option<&(dyn Error + 'static)>
1.0.0 · Source§fn description(&self) -> &str
fn description(&self) -> &str
use the Display impl or to_string()
Source§impl From<InteractionError> for OrchestratorError
impl From<InteractionError> for OrchestratorError
Source§fn from(value: InteractionError) -> Self
fn from(value: InteractionError) -> Self
Source§impl From<InteractionRejection> for InteractionError
impl From<InteractionRejection> for InteractionError
Source§fn from(value: InteractionRejection) -> Self
fn from(value: InteractionRejection) -> Self
Source§impl From<InteractionSpecError> for InteractionError
impl From<InteractionSpecError> for InteractionError
Source§fn from(value: InteractionSpecError) -> Self
fn from(value: InteractionSpecError) -> Self
Source§impl PartialEq for InteractionError
impl PartialEq for InteractionError
Source§impl Serialize for InteractionError
impl Serialize for InteractionError
impl StructuralPartialEq for InteractionError
Auto Trait Implementations§
impl Freeze for InteractionError
impl RefUnwindSafe for InteractionError
impl Send for InteractionError
impl Sync for InteractionError
impl Unpin for InteractionError
impl UnsafeUnpin for InteractionError
impl UnwindSafe for InteractionError
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
impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> DeserializeOwned for Twhere
T: for<'de> Deserialize<'de>,
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
key and return true if they are equal.