pub fn select<R, W>(self, stream: &mut MenuStream<R, W>) -> MenuResult<T>
    where
        R: BufRead,
        W: Write,
    {
        show(&self, stream)?;
        loop {
            match self.prompt_once(stream)? {
                // SAFETY: the `Selected::prompt_once` guarantees that the index is in bounds.
                Some(out) => return Ok(unsafe { self.take(out) }),
                None => continue,
            }
        }
    }
/// Prompts the selectable values to the user.
///
/// It prompts the fields once and the suffix until the index provided, then returns the selected value.
/// The output is wrapped in a [`MenuResult`] to prevent from any error (see [`MenuError`]);
///
/// This function consumes `self` because it returns the ownership of a contained value
/// (`T`) defined earlier in the [`Selected::new`] function.
Prompts the selectable values to the user.
It prompts the fields once and the suffix until the index provided, then returns the selected value.
The output is wrapped in a [`MenuResult`] to prevent from any error .


Prompts the selectable values to the user . It prompts the fields once and the suffix until the index provided then returns the selected value . The output is wrapped in a [ ` MenuResult ` ] to prevent from any error .
pub fn select<R, W>(self, stream: &mut MenuStream<R, W>) -> MenuResult<T>
    where
        R: BufRead,
        W: Write,
    {
        show(&self, stream)?;
        loop {
            match self.prompt_once(stream)? {
                // SAFETY: the `Selected::prompt_once` guarantees that the index is in bounds.
                Some(out) => return Ok(unsafe { self.take(out) }),
                None => continue,
            }
        }
    }
pub fn select < R , W > ( self , stream : & mut MenuStream < R , W > ) -> MenuResult < T > where R : BufRead , W : Write , { show ( & self , stream ) ? ; loop { match self . prompt_once ( stream ) ? { // SAFETY: the `Selected::prompt_once` guarantees that the index is in bounds. Some ( out ) => return Ok ( unsafe { self . take ( out ) } ) , None => continue , } } }
Prompts the selectable values to the user.
Prompts the selectable values to the user .
self
stream
&mut MenuStream<R, W>