Skip to main content

ConfirmationHandler

Trait ConfirmationHandler 

Source
pub trait ConfirmationHandler: Send + Sync {
    // Required method
    fn confirm(&self, op: &DestructiveOp, preview: &OperationPreview) -> bool;
}
Expand description

Trait for handling confirmation prompts before destructive operations.

Required Methods§

Source

fn confirm(&self, op: &DestructiveOp, preview: &OperationPreview) -> bool

Return true to proceed with the operation, false to cancel.

Implementors§