pub trait CaptchaVerifier: Send + Sync {
// Required methods
fn provider(&self) -> &ProviderId;
fn verify(
&self,
request: VerificationRequest,
) -> Pin<Box<dyn Future<Output = Result<VerificationResult, VerificationError>> + Send + '_>>;
}Expand description
Provider-independent interface implemented by CAPTCHA adapters.
Required Methods§
Sourcefn provider(&self) -> &ProviderId
fn provider(&self) -> &ProviderId
Identifies the backing provider.
Sourcefn verify(
&self,
request: VerificationRequest,
) -> Pin<Box<dyn Future<Output = Result<VerificationResult, VerificationError>> + Send + '_>>
fn verify( &self, request: VerificationRequest, ) -> Pin<Box<dyn Future<Output = Result<VerificationResult, VerificationError>> + Send + '_>>
Verifies a client token and returns a normalized result.
Dyn Compatibility§
This trait is dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety".