#[non_exhaustive]pub enum AcceptOutcome {
Accepted {
input_id: InputId,
policy: PolicyDecision,
state: InputState,
},
Deduplicated {
input_id: InputId,
existing_id: InputId,
},
Rejected {
reason: String,
},
}Expand description
Outcome of RuntimeDriver::accept_input().
Variants (Non-exhaustive)§
This enum is marked as non-exhaustive
Non-exhaustive enums could have additional variants added in future. Therefore, when matching against variants of non-exhaustive enums, an extra wildcard arm must be added to account for any future variants.
Accepted
Input was accepted and processing has begun.
Fields
§
policy: PolicyDecisionThe policy decision applied to this input.
§
state: InputStateCurrent input state.
Deduplicated
Input was deduplicated (idempotency key matched an existing input).
Fields
Rejected
Input was rejected (validation failed, durability violation, etc.).
Implementations§
Source§impl AcceptOutcome
impl AcceptOutcome
Sourcepub fn is_accepted(&self) -> bool
pub fn is_accepted(&self) -> bool
Check if the input was accepted.
Sourcepub fn is_deduplicated(&self) -> bool
pub fn is_deduplicated(&self) -> bool
Check if the input was deduplicated.
Sourcepub fn is_rejected(&self) -> bool
pub fn is_rejected(&self) -> bool
Check if the input was rejected.
Trait Implementations§
Source§impl Clone for AcceptOutcome
impl Clone for AcceptOutcome
Source§fn clone(&self) -> AcceptOutcome
fn clone(&self) -> AcceptOutcome
Returns a duplicate of the value. Read more
1.0.0 · 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 AcceptOutcome
impl Debug for AcceptOutcome
Source§impl<'de> Deserialize<'de> for AcceptOutcome
impl<'de> Deserialize<'de> for AcceptOutcome
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 AcceptOutcome
impl RefUnwindSafe for AcceptOutcome
impl Send for AcceptOutcome
impl Sync for AcceptOutcome
impl Unpin for AcceptOutcome
impl UnsafeUnpin for AcceptOutcome
impl UnwindSafe for AcceptOutcome
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