pub enum RedemptionFailReason {
InvalidFormat,
NotFound,
Expired,
Revoked,
AlreadyUsed,
RateLimited,
StoreUnavailable,
KeyFailure,
}Expand description
Internal reason a code redemption failed. Rich enough for logs and metrics; never shown to the user (INV-8, RFC-012 §10.1).
Variants§
InvalidFormat
Code input was malformed (too long, wrong length, unsupported chars).
NotFound
No redeemable record matched the lookup key(s).
Expired
A matching record exists but expires_at has passed.
Revoked
A matching record exists but it was explicitly revoked.
AlreadyUsed
A matching record exists but was already claimed.
RateLimited
The rate-limit threshold was exceeded before the lookup.
The store could not be reached; the operation was not attempted.
KeyFailure
Key material was unavailable or invalid.
Trait Implementations§
Source§impl Clone for RedemptionFailReason
impl Clone for RedemptionFailReason
Source§fn clone(&self) -> RedemptionFailReason
fn clone(&self) -> RedemptionFailReason
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 moreSource§impl Debug for RedemptionFailReason
impl Debug for RedemptionFailReason
impl Eq for RedemptionFailReason
Source§impl PartialEq for RedemptionFailReason
impl PartialEq for RedemptionFailReason
Source§fn eq(&self, other: &RedemptionFailReason) -> bool
fn eq(&self, other: &RedemptionFailReason) -> bool
Tests for
self and other values to be equal, and is used by ==.impl StructuralPartialEq for RedemptionFailReason
Auto Trait Implementations§
impl Freeze for RedemptionFailReason
impl RefUnwindSafe for RedemptionFailReason
impl Send for RedemptionFailReason
impl Sync for RedemptionFailReason
impl Unpin for RedemptionFailReason
impl UnsafeUnpin for RedemptionFailReason
impl UnwindSafe for RedemptionFailReason
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