pub struct GenerateArgs {
pub db_name: Option<String>,
pub versions: Vec<(usize, Version)>,
pub queries: Vec<Query>,
}Fields§
§db_name: Option<String>If you have multiple databases, use this to disambiguate them. You’ll also need
to use it in good_module! and good_query!.
versions: Vec<(usize, Version)>A list of database version ids and schema versions. The ids must be consecutive but can start from any number. Once a version has been applied to a production database it shouldn’t be modified again (modifications should be done in a new version).
These will be turned into migrations as part of the migrate function.
queries: Vec<Query>A list of queries to generate type-safe functions for. Use instead of or to
supplement good_query! if you want to programmatically generate queries.
Trait Implementations§
Auto Trait Implementations§
impl Freeze for GenerateArgs
impl !RefUnwindSafe for GenerateArgs
impl !Send for GenerateArgs
impl !Sync for GenerateArgs
impl Unpin for GenerateArgs
impl UnsafeUnpin for GenerateArgs
impl !UnwindSafe for GenerateArgs
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more