[−][src]Function brcap::search
pub fn search<'a>(query: &str, contents: &'a str) -> Vec<&'a str>
Searches into some content(text) by an specifc query provided
Examples
let query = "World"; let contents = "Welcome back into!\n Do not be afraid!\n That is my World!"; let line_matches: Vec<&str> = brcap::search(query, contents); assert_eq!(vec!["That is my World!"], line_matches);