Struct dialoguer::PasswordInput [] [src]

pub struct PasswordInput { /* fields omitted */ }

Renders a password input prompt.

Example usage

use dialoguer::PasswordInput;

let password = PasswordInput::new("New Password")
    .confirm("Confirm password", "Passwords mismatching")
    .interact()?;
println!("Length of the password is: {}", password.len());

Methods

impl PasswordInput
[src]

Creates a new input prompt.

Enables confirmation prompting.

Enables user interaction and returns the result.

If the user confirms the result is true, false otherwise. The dialog is rendered on stderr.

Like interact but allows a specific terminal to be set.