Enum hcaptcha::HcaptchaError
source · #[non_exhaustive]pub enum HcaptchaError {
Codes(HashSet<Code>),
Reqwest(Error),
Io(Error),
Json(Error),
UrlEncoded(Error),
Uuid(Error),
Url(ParseError),
}
Expand description
The error type for hcaptcha. Provides error types to capture error codes from the Hcaptcha API and errors output from crates used by the library.
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.
Codes(HashSet<Code>)
Error(s) returned from the hcaptcha API and mapped to the Code enum.
Reqwest(Error)
Error returned by reqwest
Io(Error)
Error returned by io
Json(Error)
Error returned by serde_json
UrlEncoded(Error)
Error returned by serde_urlencoded
Uuid(Error)
Error returned by uuid
Url(ParseError)
Error returned by url parser
Trait Implementations§
source§impl Debug for HcaptchaError
impl Debug for HcaptchaError
source§impl Display for HcaptchaError
impl Display for HcaptchaError
source§impl Error for HcaptchaError
impl Error for HcaptchaError
source§fn source(&self) -> Option<&(dyn Error + 'static)>
fn source(&self) -> Option<&(dyn Error + 'static)>
The lower-level source of this error, if any. Read more
1.0.0 · source§fn description(&self) -> &str
fn description(&self) -> &str
👎Deprecated since 1.42.0: use the Display impl or to_string()
source§impl From<Error> for HcaptchaError
impl From<Error> for HcaptchaError
source§impl From<Error> for HcaptchaError
impl From<Error> for HcaptchaError
source§impl From<Error> for HcaptchaError
impl From<Error> for HcaptchaError
source§impl From<Error> for HcaptchaError
impl From<Error> for HcaptchaError
source§impl From<Error> for HcaptchaError
impl From<Error> for HcaptchaError
source§impl From<ParseError> for HcaptchaError
impl From<ParseError> for HcaptchaError
source§fn from(source: ParseError) -> Self
fn from(source: ParseError) -> Self
Converts to this type from the input type.
Auto Trait Implementations§
impl !RefUnwindSafe for HcaptchaError
impl Send for HcaptchaError
impl Sync for HcaptchaError
impl Unpin for HcaptchaError
impl !UnwindSafe for HcaptchaError
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