pub struct GenerationConfigOpts<'a> {
pub table_options: HashMap<&'a str, TableOptions<'a>>,
pub default_table_options: TableOptions<'a>,
pub schema_path: String,
pub model_path: String,
pub once_common_structs: bool,
pub once_connection_type: bool,
pub readonly_prefixes: Vec<String>,
pub readonly_suffixes: Vec<String>,
}Fields§
§table_options: HashMap<&'a str, TableOptions<'a>>Specific Table options for a given table
default_table_options: TableOptions<'a>Default table options, used when not in table_options
schema_path: StringDiesel schema import path
by default crate::schema::
model_path: StringDsync model import path
by default crate::models::
once_common_structs: boolGenerate common structs only once in a “common.rs” file
once_connection_type: boolGenerate the “ConnectionType” type only once in a “common.rs” file
readonly_prefixes: Vec<String>Prefixes to treat tables as readonly
readonly_suffixes: Vec<String>Suffixes to treat tables as readonly
Implementations§
Source§impl GenerationConfigOpts<'_>
impl GenerationConfigOpts<'_>
pub fn table(&self, name: &str) -> TableOptions<'_>
Trait Implementations§
Source§impl<'a> Clone for GenerationConfigOpts<'a>
impl<'a> Clone for GenerationConfigOpts<'a>
Source§fn clone(&self) -> GenerationConfigOpts<'a>
fn clone(&self) -> GenerationConfigOpts<'a>
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl<'a> Debug for GenerationConfigOpts<'a>
impl<'a> Debug for GenerationConfigOpts<'a>
Auto Trait Implementations§
impl<'a> Freeze for GenerationConfigOpts<'a>
impl<'a> RefUnwindSafe for GenerationConfigOpts<'a>
impl<'a> Send for GenerationConfigOpts<'a>
impl<'a> Sync for GenerationConfigOpts<'a>
impl<'a> Unpin for GenerationConfigOpts<'a>
impl<'a> UnwindSafe for GenerationConfigOpts<'a>
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