#[non_exhaustive]pub struct CodegenGenericDataFieldBuilder { /* private fields */ }Expand description
A builder for CodegenGenericDataField.
Implementations§
source§impl CodegenGenericDataFieldBuilder
impl CodegenGenericDataFieldBuilder
sourcepub fn data_type(self, input: CodegenGenericDataFieldDataType) -> Self
pub fn data_type(self, input: CodegenGenericDataFieldDataType) -> Self
The data type for the generic data field.
This field is required.sourcepub fn set_data_type(
self,
input: Option<CodegenGenericDataFieldDataType>
) -> Self
pub fn set_data_type( self, input: Option<CodegenGenericDataFieldDataType> ) -> Self
The data type for the generic data field.
sourcepub fn get_data_type(&self) -> &Option<CodegenGenericDataFieldDataType>
pub fn get_data_type(&self) -> &Option<CodegenGenericDataFieldDataType>
The data type for the generic data field.
sourcepub fn data_type_value(self, input: impl Into<String>) -> Self
pub fn data_type_value(self, input: impl Into<String>) -> Self
The value of the data type for the generic data field.
This field is required.sourcepub fn set_data_type_value(self, input: Option<String>) -> Self
pub fn set_data_type_value(self, input: Option<String>) -> Self
The value of the data type for the generic data field.
sourcepub fn get_data_type_value(&self) -> &Option<String>
pub fn get_data_type_value(&self) -> &Option<String>
The value of the data type for the generic data field.
sourcepub fn required(self, input: bool) -> Self
pub fn required(self, input: bool) -> Self
Specifies whether the generic data field is required.
This field is required.sourcepub fn set_required(self, input: Option<bool>) -> Self
pub fn set_required(self, input: Option<bool>) -> Self
Specifies whether the generic data field is required.
sourcepub fn get_required(&self) -> &Option<bool>
pub fn get_required(&self) -> &Option<bool>
Specifies whether the generic data field is required.
sourcepub fn read_only(self, input: bool) -> Self
pub fn read_only(self, input: bool) -> Self
Specifies whether the generic data field is read-only.
This field is required.sourcepub fn set_read_only(self, input: Option<bool>) -> Self
pub fn set_read_only(self, input: Option<bool>) -> Self
Specifies whether the generic data field is read-only.
sourcepub fn get_read_only(&self) -> &Option<bool>
pub fn get_read_only(&self) -> &Option<bool>
Specifies whether the generic data field is read-only.
sourcepub fn is_array(self, input: bool) -> Self
pub fn is_array(self, input: bool) -> Self
Specifies whether the generic data field is an array.
This field is required.sourcepub fn set_is_array(self, input: Option<bool>) -> Self
pub fn set_is_array(self, input: Option<bool>) -> Self
Specifies whether the generic data field is an array.
sourcepub fn get_is_array(&self) -> &Option<bool>
pub fn get_is_array(&self) -> &Option<bool>
Specifies whether the generic data field is an array.
sourcepub fn relationship(self, input: CodegenGenericDataRelationshipType) -> Self
pub fn relationship(self, input: CodegenGenericDataRelationshipType) -> Self
The relationship of the generic data schema.
sourcepub fn set_relationship(
self,
input: Option<CodegenGenericDataRelationshipType>
) -> Self
pub fn set_relationship( self, input: Option<CodegenGenericDataRelationshipType> ) -> Self
The relationship of the generic data schema.
sourcepub fn get_relationship(&self) -> &Option<CodegenGenericDataRelationshipType>
pub fn get_relationship(&self) -> &Option<CodegenGenericDataRelationshipType>
The relationship of the generic data schema.
sourcepub fn build(self) -> Result<CodegenGenericDataField, BuildError>
pub fn build(self) -> Result<CodegenGenericDataField, BuildError>
Consumes the builder and constructs a CodegenGenericDataField.
This method will fail if any of the following fields are not set:
Trait Implementations§
source§impl Clone for CodegenGenericDataFieldBuilder
impl Clone for CodegenGenericDataFieldBuilder
source§fn clone(&self) -> CodegenGenericDataFieldBuilder
fn clone(&self) -> CodegenGenericDataFieldBuilder
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moresource§impl Default for CodegenGenericDataFieldBuilder
impl Default for CodegenGenericDataFieldBuilder
source§fn default() -> CodegenGenericDataFieldBuilder
fn default() -> CodegenGenericDataFieldBuilder
source§impl PartialEq for CodegenGenericDataFieldBuilder
impl PartialEq for CodegenGenericDataFieldBuilder
source§fn eq(&self, other: &CodegenGenericDataFieldBuilder) -> bool
fn eq(&self, other: &CodegenGenericDataFieldBuilder) -> bool
self and other values to be equal, and is used
by ==.impl StructuralPartialEq for CodegenGenericDataFieldBuilder
Auto Trait Implementations§
impl Freeze for CodegenGenericDataFieldBuilder
impl RefUnwindSafe for CodegenGenericDataFieldBuilder
impl Send for CodegenGenericDataFieldBuilder
impl Sync for CodegenGenericDataFieldBuilder
impl Unpin for CodegenGenericDataFieldBuilder
impl UnwindSafe for CodegenGenericDataFieldBuilder
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
source§impl<T> Instrument for T
impl<T> Instrument for T
source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
source§impl<T> IntoEither for T
impl<T> IntoEither for T
source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moresource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more