pub trait Interactor {
    // Required methods
    fn input(&self, prompt: &str) -> String;
    fn input_letter(&self, prompt: &str, choices: &str) -> String;
    fn select(&self, prompt: &str, choices: &[&str]) -> Option<usize>;
    fn confirm(&self, prompt: &str) -> bool;

    // Provided methods
    fn info(&self, message: &str) { ... }
    fn error(&self, message: &str) { ... }
}

Required Methods§

source

fn input(&self, prompt: &str) -> String

source

fn input_letter(&self, prompt: &str, choices: &str) -> String

source

fn select(&self, prompt: &str, choices: &[&str]) -> Option<usize>

source

fn confirm(&self, prompt: &str) -> bool

Provided Methods§

source

fn info(&self, message: &str)

source

fn error(&self, message: &str)

Implementors§