1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16
use serde::{Deserialize, Serialize}; ///Read options when reading from mongodb #[derive(Debug, Clone, Serialize, Deserialize)] pub struct ReadOptions<T> { ///field to search collection by pub read_by: String, ///identifiers when looking at the read_by pub ids: Vec<T>, ///offset to start reading from the db pub offset: u32, ///obtain the offset + next documents pub next: u32, ///sort the documents by time pub sort: bool, }