#[non_exhaustive]pub enum AcceptOutcome {
Accepted {
input_id: InputId,
policy: PolicyDecision,
state: InputState,
},
Deduplicated {
input_id: InputId,
existing_id: InputId,
},
Rejected {
reason: RejectReason,
},
}Expand description
Outcome of RuntimeDriver::accept_input().
Domain envelope returned to in-process callers. Surface crates translate it
into the wire shape (RuntimeAcceptResult in meerkat-contracts) before
emitting it on the network, so this type intentionally has no
Serialize/Deserialize derives.
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.).
Fields
§
reason: RejectReasonWhy the input was rejected.
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 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreAuto 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