#[non_exhaustive]pub struct CodegenGenericDataModelBuilder { /* private fields */ }Expand description
A builder for CodegenGenericDataModel.
Implementations§
source§impl CodegenGenericDataModelBuilder
 
impl CodegenGenericDataModelBuilder
sourcepub fn fields(self, k: impl Into<String>, v: CodegenGenericDataField) -> Self
 
pub fn fields(self, k: impl Into<String>, v: CodegenGenericDataField) -> Self
Adds a key-value pair to fields.
To override the contents of this collection use set_fields.
The fields in the generic data model.
sourcepub fn set_fields(
    self,
    input: Option<HashMap<String, CodegenGenericDataField>>
) -> Self
 
pub fn set_fields( self, input: Option<HashMap<String, CodegenGenericDataField>> ) -> Self
The fields in the generic data model.
sourcepub fn get_fields(&self) -> &Option<HashMap<String, CodegenGenericDataField>>
 
pub fn get_fields(&self) -> &Option<HashMap<String, CodegenGenericDataField>>
The fields in the generic data model.
sourcepub fn is_join_table(self, input: bool) -> Self
 
pub fn is_join_table(self, input: bool) -> Self
Specifies whether the generic data model is a join table.
sourcepub fn set_is_join_table(self, input: Option<bool>) -> Self
 
pub fn set_is_join_table(self, input: Option<bool>) -> Self
Specifies whether the generic data model is a join table.
sourcepub fn get_is_join_table(&self) -> &Option<bool>
 
pub fn get_is_join_table(&self) -> &Option<bool>
Specifies whether the generic data model is a join table.
sourcepub fn primary_keys(self, input: impl Into<String>) -> Self
 
pub fn primary_keys(self, input: impl Into<String>) -> Self
Appends an item to primary_keys.
To override the contents of this collection use set_primary_keys.
The primary keys of the generic data model.
sourcepub fn set_primary_keys(self, input: Option<Vec<String>>) -> Self
 
pub fn set_primary_keys(self, input: Option<Vec<String>>) -> Self
The primary keys of the generic data model.
sourcepub fn get_primary_keys(&self) -> &Option<Vec<String>>
 
pub fn get_primary_keys(&self) -> &Option<Vec<String>>
The primary keys of the generic data model.
sourcepub fn build(self) -> Result<CodegenGenericDataModel, BuildError>
 
pub fn build(self) -> Result<CodegenGenericDataModel, BuildError>
Consumes the builder and constructs a CodegenGenericDataModel.
This method will fail if any of the following fields are not set:
Trait Implementations§
source§impl Clone for CodegenGenericDataModelBuilder
 
impl Clone for CodegenGenericDataModelBuilder
source§fn clone(&self) -> CodegenGenericDataModelBuilder
 
fn clone(&self) -> CodegenGenericDataModelBuilder
1.0.0 · source§fn clone_from(&mut self, source: &Self)
 
fn clone_from(&mut self, source: &Self)
source. Read moresource§impl Default for CodegenGenericDataModelBuilder
 
impl Default for CodegenGenericDataModelBuilder
source§fn default() -> CodegenGenericDataModelBuilder
 
fn default() -> CodegenGenericDataModelBuilder
source§impl PartialEq for CodegenGenericDataModelBuilder
 
impl PartialEq for CodegenGenericDataModelBuilder
source§fn eq(&self, other: &CodegenGenericDataModelBuilder) -> bool
 
fn eq(&self, other: &CodegenGenericDataModelBuilder) -> bool
self and other values to be equal, and is used
by ==.