pub struct RecaptchaMetadata {
pub grid: RecaptchaGrid,
pub task: Option<String>,
pub task_definition: Option<String>,
}Expand description
metadata of the reCAPTCHA click task.
The docs require Grid and at least one of Task / TaskDefinition.
Fields§
§grid: RecaptchaGridImage grid size.
task: Option<String>Task name in English, e.g. Click on traffic lights.
task_definition: Option<String>Technical task identifier, e.g. /m/015qff (taken from the /recaptcha/<api>/reload or
/userverify response).
Implementations§
Source§impl RecaptchaMetadata
impl RecaptchaMetadata
Sourcepub fn from_task(grid: RecaptchaGrid, task: impl Into<String>) -> Self
pub fn from_task(grid: RecaptchaGrid, task: impl Into<String>) -> Self
Metadata identified by the task name.
Sourcepub fn from_task_definition(
grid: RecaptchaGrid,
task_definition: impl Into<String>,
) -> Self
pub fn from_task_definition( grid: RecaptchaGrid, task_definition: impl Into<String>, ) -> Self
Metadata identified by the technical TaskDefinition value.
pub fn with_task(self, value: impl Into<String>) -> Self
pub fn with_task_definition(self, value: impl Into<String>) -> Self
Trait Implementations§
Source§impl Clone for RecaptchaMetadata
impl Clone for RecaptchaMetadata
Source§impl Debug for RecaptchaMetadata
impl Debug for RecaptchaMetadata
impl Eq for RecaptchaMetadata
Source§impl PartialEq for RecaptchaMetadata
impl PartialEq for RecaptchaMetadata
Source§impl Serialize for RecaptchaMetadata
impl Serialize for RecaptchaMetadata
impl StructuralPartialEq for RecaptchaMetadata
Auto Trait Implementations§
impl Freeze for RecaptchaMetadata
impl RefUnwindSafe for RecaptchaMetadata
impl Send for RecaptchaMetadata
impl Sync for RecaptchaMetadata
impl Unpin for RecaptchaMetadata
impl UnsafeUnpin for RecaptchaMetadata
impl UnwindSafe for RecaptchaMetadata
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