Function omdb::query::search [−][src]
pub fn search<S: Into<String>>(search: S) -> SearchQuery
Expand description
Starts a new SearchQuery
.
This can be built upon to add other constraints while searchign for a movie on OMDb. Use this function when you’re trying to select multiple movies that fit a set of constraints.
Examples
Search for movies:
let apikey = std::env::var("OMDB_APIKEY").expect("OMDB_APIKEY must be set"); let movies = omdb::search("batman").apikey(apikey).get().await.unwrap(); assert!(movies.total_results > 0);