pub struct CodegenConfig {
pub schema_file: PathBuf,
pub include_tables: String,
pub exclude_tables: String,
pub generate_structs: bool,
pub generate_dao: bool,
pub output_structs_dir: PathBuf,
pub output_dao_dir: PathBuf,
pub models_module: String,
pub dao_module: String,
pub dry_run: bool,
pub log_level: Option<String>,
}Expand description
Main configuration struct for code generation
Fields§
§schema_file: PathBufPath to the SQL schema file
include_tables: StringTables to include (comma-separated, or “*” for all)
exclude_tables: StringTables to exclude (comma-separated)
generate_structs: boolWhether to generate struct files
generate_dao: boolWhether to generate DAO files
output_structs_dir: PathBufOutput directory for generated structs
output_dao_dir: PathBufOutput directory for generated DAOs
models_module: StringModule name for structs
dao_module: StringModule name for DAOs
dry_run: boolDry run mode - preview without writing files
log_level: Option<String>Log level (trace, debug, info, warn, error) Can be overridden by RUST_LOG env var
Implementations§
Trait Implementations§
Source§impl Clone for CodegenConfig
impl Clone for CodegenConfig
Source§fn clone(&self) -> CodegenConfig
fn clone(&self) -> CodegenConfig
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 Debug for CodegenConfig
impl Debug for CodegenConfig
Source§impl Default for CodegenConfig
impl Default for CodegenConfig
Source§impl<'de> Deserialize<'de> for CodegenConfig
impl<'de> Deserialize<'de> for CodegenConfig
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Auto Trait Implementations§
impl Freeze for CodegenConfig
impl RefUnwindSafe for CodegenConfig
impl Send for CodegenConfig
impl Sync for CodegenConfig
impl Unpin for CodegenConfig
impl UnwindSafe for CodegenConfig
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