pub struct CodegenParams {
pub database: DatabaseEngine,
pub language: Language,
pub database_access_mode: Option<DatabaseAccessMode>,
pub namespace: Option<String>,
pub type_name_transform: Option<NameTransform>,
pub field_name_transform: Option<NameTransform>,
pub variant_name_transform: Option<NameTransform>,
pub func_name_transform: Option<NameTransform>,
pub namespace_transform: Option<NameTransform>,
}Expand description
A bunch of centralized settings governing the behavior of DALGen.
Fields§
§database: DatabaseEngineThe database flavor to be targeted. See the docs of DatabaseEngine.
language: LanguageThe programming language to be targeted. See the docs of Language.
database_access_mode: Option<DatabaseAccessMode>Database access strategy. See the docs for DatabaseAccessMode.
namespace: Option<String>Namespace name. This will be used in different ways for different programming languages. For example, in Go, it will be the package name, and is thus mandatory.
type_name_transform: Option<NameTransform>The transform to be applied to names of user-defined types.
field_name_transform: Option<NameTransform>The transform to be applied to fields of structs and classes.
variant_name_transform: Option<NameTransform>The transform to be applied to variants of enums.
func_name_transform: Option<NameTransform>The transform to be applied to names of user-defined functions.
namespace_transform: Option<NameTransform>The transform to be applied to the name of the namespace.
Trait Implementations§
Source§impl Clone for CodegenParams
impl Clone for CodegenParams
Source§fn clone(&self) -> CodegenParams
fn clone(&self) -> CodegenParams
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 CodegenParams
impl Debug for CodegenParams
Source§impl Hash for CodegenParams
impl Hash for CodegenParams
Source§impl Ord for CodegenParams
impl Ord for CodegenParams
Source§fn cmp(&self, other: &CodegenParams) -> Ordering
fn cmp(&self, other: &CodegenParams) -> Ordering
1.21.0 · Source§fn max(self, other: Self) -> Selfwhere
Self: Sized,
fn max(self, other: Self) -> Selfwhere
Self: Sized,
Compares and returns the maximum of two values. Read more
Source§impl PartialEq for CodegenParams
impl PartialEq for CodegenParams
Source§impl PartialOrd for CodegenParams
impl PartialOrd for CodegenParams
impl Eq for CodegenParams
impl StructuralPartialEq for CodegenParams
Auto Trait Implementations§
impl Freeze for CodegenParams
impl RefUnwindSafe for CodegenParams
impl Send for CodegenParams
impl Sync for CodegenParams
impl Unpin for CodegenParams
impl UnwindSafe for CodegenParams
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