You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
/// let client = Client::new(MEILISEARCH_HOST, MEILISEARCH_API_KEY);
304
296
/// let movies = client.index("get_document");
305
-
/// # movies.add_or_replace(&[Movie{name:String::from("Interstellar"), description:String::from("Interstellar chronicles the adventures of a group of explorers who make use of a newly discovered wormhole to surpass the limitations on human space travel and conquer the vast distances involved in an interstellar voyage."), age: Some(1)}], Some("name")).await.unwrap().wait_for_completion(&client, None, None).await.unwrap();
297
+
/// # movies.add_or_replace(&[Movie{name:String::from("Interstellar"), description:String::from("Interstellar chronicles the adventures of a group of explorers who make use of a newly discovered wormhole to surpass the limitations on human space travel and conquer the vast distances involved in an interstellar voyage.")}], Some("name")).await.unwrap().wait_for_completion(&client, None, None).await.unwrap();
306
298
///
307
299
/// // retrieve a document (you have to put the document in the index before)
308
-
/// let interstellar = movies.get_document::<ReturnedMovie>("Interstellar", Some(["name", "description"].to_vec())).await.unwrap();
300
+
/// let interstellar = movies.get_document::<Movie>("Interstellar").await.unwrap();
309
301
///
310
-
/// assert_eq!(interstellar, ReturnedMovie {
302
+
/// assert_eq!(interstellar, Movie {
311
303
/// name: String::from("Interstellar"),
312
304
/// description: String::from("Interstellar chronicles the adventures of a group of explorers who make use of a newly discovered wormhole to surpass the limitations on human space travel and conquer the vast distances involved in an interstellar voyage."),
0 commit comments