pub fn find_all_strings(&self, name: &str) -> Result<Vec<Token<String>>> {
        let mut out: Vec<Token<String>> = Vec::new();

        for s in self.lookup(name) {
            match **s {
                Value::String(ref string) => {
                    out.push(Token::new(string.clone(), s.pos.clone()));
                }
                _ => {
                    return Err(Error::pos(format!("{}: expected string", name), s.pos.clone()));
                }
            }
        }

        Ok(out)
    }
/// Find all strings matching the given name.
///
/// This enforces that all found values are strings, otherwise the lookup will cause an error.
Find all strings matching the given name.
This enforces that all found values are strings, otherwise the lookup will cause an error.
Find all strings matching the given name . This enforces that all found values are strings otherwise the lookup will cause an error .
pub fn find_all_strings(&self, name: &str) -> Result<Vec<Token<String>>> {
        let mut out: Vec<Token<String>> = Vec::new();
        for s in self.lookup(name) {
            match **s {
                Value::String(ref string) => {
                    out.push(Token::new(string.clone(), s.pos.clone()));
                }
                _ => {
                    return Err(Error::pos(format!("{}: expected string", name), s.pos.clone()));
                }
            }
        }
        Ok(out)
    }
pub fn find_all_strings ( & self , name : & str ) -> Result < Vec < Token < String > > > { let mut out : Vec < Token < String > > = Vec :: new ( ) ; for s in self . lookup ( name ) { match * * s { Value :: String ( ref string ) => { out . push ( Token :: new ( string . clone ( ) , s . pos . clone ( ) ) ) ; } _ => { return Err ( Error :: pos ( format ! ( " " name ) , s . pos . clone ( ) ) ) ; } } } Ok ( out ) }
Find all strings matching the given name.
Find all strings matching the given name .
&self
name
&str
&self
name
&str