#[non_exhaustive]pub enum FailureReason {
MissingToken,
InvalidToken,
AlreadyUsed,
Expired,
HostnameMismatch,
ActionMismatch,
ScoreTooLow,
Other(String),
}Expand description
A normalized reason explaining why a CAPTCHA was not accepted.
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.
MissingToken
The token was missing or empty.
InvalidToken
The token was malformed or invalid.
AlreadyUsed
The token was already consumed.
Expired
The token expired before verification.
HostnameMismatch
The returned hostname did not match application policy.
ActionMismatch
The returned action did not match the requested action.
ScoreTooLow
The score was below application policy.
Other(String)
The provider returned a reason that does not have a normalized variant.
Trait Implementations§
Source§impl Clone for FailureReason
impl Clone for FailureReason
Source§fn clone(&self) -> FailureReason
fn clone(&self) -> FailureReason
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 FailureReason
impl Debug for FailureReason
Source§impl<'de> Deserialize<'de> for FailureReason
impl<'de> Deserialize<'de> for FailureReason
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
impl Eq for FailureReason
Source§impl PartialEq for FailureReason
impl PartialEq for FailureReason
Source§impl Serialize for FailureReason
impl Serialize for FailureReason
impl StructuralPartialEq for FailureReason
Auto Trait Implementations§
impl Freeze for FailureReason
impl RefUnwindSafe for FailureReason
impl Send for FailureReason
impl Sync for FailureReason
impl Unpin for FailureReason
impl UnsafeUnpin for FailureReason
impl UnwindSafe for FailureReason
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