#[non_exhaustive]pub struct EnrollProgress {
pub completed_stages: u32,
pub total_stages: u32,
pub retry: Option<RetryReason>,
pub finger_status: FingerStatus,
}Expand description
Progress report delivered during Device::enroll, once per capture attempt.
Fields (Non-exhaustive)§
This struct is marked as non-exhaustive
Non-exhaustive structs could have additional fields added in future. Therefore, non-exhaustive structs cannot be constructed in external crates using the traditional
Struct { .. } syntax; cannot be matched against without a wildcard ..; and struct update syntax will not work.completed_stages: u32Stages completed so far (0..=total_stages).
total_stages: u32Stages a full enrollment needs, mirroring DeviceInfo::enroll_stages.
retry: Option<RetryReason>Some when this capture failed and the user should present the finger again;
the stage count did not advance.
finger_status: FingerStatusLive finger-presence status accompanying this report (FingerStatus::NONE when the
backend reports none).
Implementations§
Source§impl EnrollProgress
impl EnrollProgress
Sourcepub fn new(completed_stages: u32, total_stages: u32) -> Self
pub fn new(completed_stages: u32, total_stages: u32) -> Self
A report of completed_stages of total_stages, with no retry and no finger status.
Sourcepub fn with_retry(self, r: RetryReason) -> Self
pub fn with_retry(self, r: RetryReason) -> Self
Mark this report as a retry with reason r.
Sourcepub fn with_finger_status(self, s: FingerStatus) -> Self
pub fn with_finger_status(self, s: FingerStatus) -> Self
Attach the live finger-presence status.
Trait Implementations§
Source§impl Clone for EnrollProgress
impl Clone for EnrollProgress
Source§impl Debug for EnrollProgress
impl Debug for EnrollProgress
impl Eq for EnrollProgress
Source§impl PartialEq for EnrollProgress
impl PartialEq for EnrollProgress
impl StructuralPartialEq for EnrollProgress
Auto Trait Implementations§
impl Freeze for EnrollProgress
impl RefUnwindSafe for EnrollProgress
impl Send for EnrollProgress
impl Sync for EnrollProgress
impl Unpin for EnrollProgress
impl UnsafeUnpin for EnrollProgress
impl UnwindSafe for EnrollProgress
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