Struct dialoguer::Checkboxes
[−]
[src]
pub struct Checkboxes { /* fields omitted */ }
Renders a multi select checkbox menu.
Methods
impl Checkboxes
[src]
fn new() -> Checkboxes
Creates the prompt with a specific text.
fn clear(&mut self, val: bool) -> &mut Checkboxes
Sets the clear behavior of the checkbox menu.
The default is to clear the checkbox menu.
fn item(&mut self, item: &str) -> &mut Checkboxes
Add a single item to the selector.
fn items(&mut self, items: &[&str]) -> &mut Checkboxes
Adds multiple items to the selector.
fn interact(&self) -> Result<Vec<usize>>
Enables user interaction and returns the result.
The user can select the items with the space bar and on enter the selected items will be returned.
fn interact_on(&self, term: &Term) -> Result<Vec<usize>>
Like interact
but allows a specific terminal to be set.