#[non_exhaustive]
#[derive(::std::clone::Clone, ::std::cmp::PartialEq)]
pub struct DetectedProfileObjectType {
pub source_last_updated_timestamp_format: ::std::option::Option<::std::string::String>,
pub fields: ::std::option::Option<::std::collections::HashMap<::std::string::String, crate::types::ObjectTypeField>>,
pub keys: ::std::option::Option<::std::collections::HashMap<::std::string::String, ::std::vec::Vec<crate::types::ObjectTypeKey>>>,
}
impl DetectedProfileObjectType {
pub fn source_last_updated_timestamp_format(&self) -> ::std::option::Option<&str> {
self.source_last_updated_timestamp_format.as_deref()
}
pub fn fields(&self) -> ::std::option::Option<&::std::collections::HashMap<::std::string::String, crate::types::ObjectTypeField>> {
self.fields.as_ref()
}
pub fn keys(&self) -> ::std::option::Option<&::std::collections::HashMap<::std::string::String, ::std::vec::Vec<crate::types::ObjectTypeKey>>> {
self.keys.as_ref()
}
}
impl ::std::fmt::Debug for DetectedProfileObjectType {
fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result {
let mut formatter = f.debug_struct("DetectedProfileObjectType");
formatter.field("source_last_updated_timestamp_format", &self.source_last_updated_timestamp_format);
formatter.field("fields", &"*** Sensitive Data Redacted ***");
formatter.field("keys", &"*** Sensitive Data Redacted ***");
formatter.finish()
}
}
impl DetectedProfileObjectType {
pub fn builder() -> crate::types::builders::DetectedProfileObjectTypeBuilder {
crate::types::builders::DetectedProfileObjectTypeBuilder::default()
}
}
#[non_exhaustive]
#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::default::Default)]
pub struct DetectedProfileObjectTypeBuilder {
pub(crate) source_last_updated_timestamp_format: ::std::option::Option<::std::string::String>,
pub(crate) fields: ::std::option::Option<::std::collections::HashMap<::std::string::String, crate::types::ObjectTypeField>>,
pub(crate) keys: ::std::option::Option<::std::collections::HashMap<::std::string::String, ::std::vec::Vec<crate::types::ObjectTypeKey>>>,
}
impl DetectedProfileObjectTypeBuilder {
pub fn source_last_updated_timestamp_format(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
self.source_last_updated_timestamp_format = ::std::option::Option::Some(input.into());
self
}
pub fn set_source_last_updated_timestamp_format(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
self.source_last_updated_timestamp_format = input;
self
}
pub fn get_source_last_updated_timestamp_format(&self) -> &::std::option::Option<::std::string::String> {
&self.source_last_updated_timestamp_format
}
pub fn fields(mut self, k: impl ::std::convert::Into<::std::string::String>, v: crate::types::ObjectTypeField) -> Self {
let mut hash_map = self.fields.unwrap_or_default();
hash_map.insert(k.into(), v);
self.fields = ::std::option::Option::Some(hash_map);
self
}
pub fn set_fields(
mut self,
input: ::std::option::Option<::std::collections::HashMap<::std::string::String, crate::types::ObjectTypeField>>,
) -> Self {
self.fields = input;
self
}
pub fn get_fields(&self) -> &::std::option::Option<::std::collections::HashMap<::std::string::String, crate::types::ObjectTypeField>> {
&self.fields
}
pub fn keys(mut self, k: impl ::std::convert::Into<::std::string::String>, v: ::std::vec::Vec<crate::types::ObjectTypeKey>) -> Self {
let mut hash_map = self.keys.unwrap_or_default();
hash_map.insert(k.into(), v);
self.keys = ::std::option::Option::Some(hash_map);
self
}
pub fn set_keys(
mut self,
input: ::std::option::Option<::std::collections::HashMap<::std::string::String, ::std::vec::Vec<crate::types::ObjectTypeKey>>>,
) -> Self {
self.keys = input;
self
}
pub fn get_keys(
&self,
) -> &::std::option::Option<::std::collections::HashMap<::std::string::String, ::std::vec::Vec<crate::types::ObjectTypeKey>>> {
&self.keys
}
pub fn build(self) -> crate::types::DetectedProfileObjectType {
crate::types::DetectedProfileObjectType {
source_last_updated_timestamp_format: self.source_last_updated_timestamp_format,
fields: self.fields,
keys: self.keys,
}
}
}
impl ::std::fmt::Debug for DetectedProfileObjectTypeBuilder {
fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result {
let mut formatter = f.debug_struct("DetectedProfileObjectTypeBuilder");
formatter.field("source_last_updated_timestamp_format", &self.source_last_updated_timestamp_format);
formatter.field("fields", &"*** Sensitive Data Redacted ***");
formatter.field("keys", &"*** Sensitive Data Redacted ***");
formatter.finish()
}
}