#[allow(missing_docs)] #[non_exhaustive]
#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::fmt::Debug)]
pub struct GetDimensionOutput {
#[allow(missing_docs)] pub dimension: ::std::string::String,
#[allow(missing_docs)] pub position: i32,
pub schema: ::std::collections::HashMap::<::std::string::String, ::aws_smithy_types::Document>,
#[allow(missing_docs)] pub value_validation_function_name: ::std::option::Option<::std::string::String>,
#[allow(missing_docs)] pub description: ::std::string::String,
#[allow(missing_docs)] pub change_reason: ::std::string::String,
#[allow(missing_docs)] pub last_modified_at: ::aws_smithy_types::DateTime,
#[allow(missing_docs)] pub last_modified_by: ::std::string::String,
#[allow(missing_docs)] pub created_at: ::aws_smithy_types::DateTime,
#[allow(missing_docs)] pub created_by: ::std::string::String,
#[allow(missing_docs)] pub dependency_graph: ::std::collections::HashMap::<::std::string::String, ::std::vec::Vec::<::std::string::String>>,
#[allow(missing_docs)] pub dimension_type: crate::types::DimensionType,
#[allow(missing_docs)] pub value_compute_function_name: ::std::option::Option<::std::string::String>,
#[allow(missing_docs)] pub mandatory: bool,
}
impl GetDimensionOutput {
#[allow(missing_docs)] pub fn dimension(&self) -> &str {
use std::ops::Deref; self.dimension.deref()
}
#[allow(missing_docs)] pub fn position(&self) -> i32 {
self.position
}
pub fn schema(&self) -> &::std::collections::HashMap::<::std::string::String, ::aws_smithy_types::Document> {
&self.schema
}
#[allow(missing_docs)] pub fn value_validation_function_name(&self) -> ::std::option::Option<&str> {
self.value_validation_function_name.as_deref()
}
#[allow(missing_docs)] pub fn description(&self) -> &str {
use std::ops::Deref; self.description.deref()
}
#[allow(missing_docs)] pub fn change_reason(&self) -> &str {
use std::ops::Deref; self.change_reason.deref()
}
#[allow(missing_docs)] pub fn last_modified_at(&self) -> &::aws_smithy_types::DateTime {
&self.last_modified_at
}
#[allow(missing_docs)] pub fn last_modified_by(&self) -> &str {
use std::ops::Deref; self.last_modified_by.deref()
}
#[allow(missing_docs)] pub fn created_at(&self) -> &::aws_smithy_types::DateTime {
&self.created_at
}
#[allow(missing_docs)] pub fn created_by(&self) -> &str {
use std::ops::Deref; self.created_by.deref()
}
#[allow(missing_docs)] pub fn dependency_graph(&self) -> &::std::collections::HashMap::<::std::string::String, ::std::vec::Vec::<::std::string::String>> {
&self.dependency_graph
}
#[allow(missing_docs)] pub fn dimension_type(&self) -> &crate::types::DimensionType {
&self.dimension_type
}
#[allow(missing_docs)] pub fn value_compute_function_name(&self) -> ::std::option::Option<&str> {
self.value_compute_function_name.as_deref()
}
#[allow(missing_docs)] pub fn mandatory(&self) -> bool {
self.mandatory
}
}
impl GetDimensionOutput {
pub fn builder() -> crate::operation::get_dimension::builders::GetDimensionOutputBuilder {
crate::operation::get_dimension::builders::GetDimensionOutputBuilder::default()
}
}
#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::default::Default, ::std::fmt::Debug)]
#[non_exhaustive]
pub struct GetDimensionOutputBuilder {
pub(crate) dimension: ::std::option::Option<::std::string::String>,
pub(crate) position: ::std::option::Option<i32>,
pub(crate) schema: ::std::option::Option<::std::collections::HashMap::<::std::string::String, ::aws_smithy_types::Document>>,
pub(crate) value_validation_function_name: ::std::option::Option<::std::string::String>,
pub(crate) description: ::std::option::Option<::std::string::String>,
pub(crate) change_reason: ::std::option::Option<::std::string::String>,
pub(crate) last_modified_at: ::std::option::Option<::aws_smithy_types::DateTime>,
pub(crate) last_modified_by: ::std::option::Option<::std::string::String>,
pub(crate) created_at: ::std::option::Option<::aws_smithy_types::DateTime>,
pub(crate) created_by: ::std::option::Option<::std::string::String>,
pub(crate) dependency_graph: ::std::option::Option<::std::collections::HashMap::<::std::string::String, ::std::vec::Vec::<::std::string::String>>>,
pub(crate) dimension_type: ::std::option::Option<crate::types::DimensionType>,
pub(crate) value_compute_function_name: ::std::option::Option<::std::string::String>,
pub(crate) mandatory: ::std::option::Option<bool>,
}
impl GetDimensionOutputBuilder {
#[allow(missing_docs)] pub fn dimension(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
self.dimension = ::std::option::Option::Some(input.into());
self
}
#[allow(missing_docs)] pub fn set_dimension(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
self.dimension = input; self
}
#[allow(missing_docs)] pub fn get_dimension(&self) -> &::std::option::Option<::std::string::String> {
&self.dimension
}
#[allow(missing_docs)] pub fn position(mut self, input: i32) -> Self {
self.position = ::std::option::Option::Some(input);
self
}
#[allow(missing_docs)] pub fn set_position(mut self, input: ::std::option::Option<i32>) -> Self {
self.position = input; self
}
#[allow(missing_docs)] pub fn get_position(&self) -> &::std::option::Option<i32> {
&self.position
}
pub fn schema(mut self, k: impl ::std::convert::Into<::std::string::String>, v: ::aws_smithy_types::Document) -> Self {
let mut hash_map = self.schema.unwrap_or_default();
hash_map.insert(k.into(), v);
self.schema = ::std::option::Option::Some(hash_map);
self
}
pub fn set_schema(mut self, input: ::std::option::Option<::std::collections::HashMap::<::std::string::String, ::aws_smithy_types::Document>>) -> Self {
self.schema = input; self
}
pub fn get_schema(&self) -> &::std::option::Option<::std::collections::HashMap::<::std::string::String, ::aws_smithy_types::Document>> {
&self.schema
}
#[allow(missing_docs)] pub fn value_validation_function_name(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
self.value_validation_function_name = ::std::option::Option::Some(input.into());
self
}
#[allow(missing_docs)] pub fn set_value_validation_function_name(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
self.value_validation_function_name = input; self
}
#[allow(missing_docs)] pub fn get_value_validation_function_name(&self) -> &::std::option::Option<::std::string::String> {
&self.value_validation_function_name
}
#[allow(missing_docs)] pub fn description(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
self.description = ::std::option::Option::Some(input.into());
self
}
#[allow(missing_docs)] pub fn set_description(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
self.description = input; self
}
#[allow(missing_docs)] pub fn get_description(&self) -> &::std::option::Option<::std::string::String> {
&self.description
}
#[allow(missing_docs)] pub fn change_reason(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
self.change_reason = ::std::option::Option::Some(input.into());
self
}
#[allow(missing_docs)] pub fn set_change_reason(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
self.change_reason = input; self
}
#[allow(missing_docs)] pub fn get_change_reason(&self) -> &::std::option::Option<::std::string::String> {
&self.change_reason
}
#[allow(missing_docs)] pub fn last_modified_at(mut self, input: ::aws_smithy_types::DateTime) -> Self {
self.last_modified_at = ::std::option::Option::Some(input);
self
}
#[allow(missing_docs)] pub fn set_last_modified_at(mut self, input: ::std::option::Option<::aws_smithy_types::DateTime>) -> Self {
self.last_modified_at = input; self
}
#[allow(missing_docs)] pub fn get_last_modified_at(&self) -> &::std::option::Option<::aws_smithy_types::DateTime> {
&self.last_modified_at
}
#[allow(missing_docs)] pub fn last_modified_by(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
self.last_modified_by = ::std::option::Option::Some(input.into());
self
}
#[allow(missing_docs)] pub fn set_last_modified_by(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
self.last_modified_by = input; self
}
#[allow(missing_docs)] pub fn get_last_modified_by(&self) -> &::std::option::Option<::std::string::String> {
&self.last_modified_by
}
#[allow(missing_docs)] pub fn created_at(mut self, input: ::aws_smithy_types::DateTime) -> Self {
self.created_at = ::std::option::Option::Some(input);
self
}
#[allow(missing_docs)] pub fn set_created_at(mut self, input: ::std::option::Option<::aws_smithy_types::DateTime>) -> Self {
self.created_at = input; self
}
#[allow(missing_docs)] pub fn get_created_at(&self) -> &::std::option::Option<::aws_smithy_types::DateTime> {
&self.created_at
}
#[allow(missing_docs)] pub fn created_by(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
self.created_by = ::std::option::Option::Some(input.into());
self
}
#[allow(missing_docs)] pub fn set_created_by(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
self.created_by = input; self
}
#[allow(missing_docs)] pub fn get_created_by(&self) -> &::std::option::Option<::std::string::String> {
&self.created_by
}
pub fn dependency_graph(mut self, k: impl ::std::convert::Into<::std::string::String>, v: ::std::vec::Vec::<::std::string::String>) -> Self {
let mut hash_map = self.dependency_graph.unwrap_or_default();
hash_map.insert(k.into(), v);
self.dependency_graph = ::std::option::Option::Some(hash_map);
self
}
#[allow(missing_docs)] pub fn set_dependency_graph(mut self, input: ::std::option::Option<::std::collections::HashMap::<::std::string::String, ::std::vec::Vec::<::std::string::String>>>) -> Self {
self.dependency_graph = input; self
}
#[allow(missing_docs)] pub fn get_dependency_graph(&self) -> &::std::option::Option<::std::collections::HashMap::<::std::string::String, ::std::vec::Vec::<::std::string::String>>> {
&self.dependency_graph
}
#[allow(missing_docs)] pub fn dimension_type(mut self, input: crate::types::DimensionType) -> Self {
self.dimension_type = ::std::option::Option::Some(input);
self
}
#[allow(missing_docs)] pub fn set_dimension_type(mut self, input: ::std::option::Option<crate::types::DimensionType>) -> Self {
self.dimension_type = input; self
}
#[allow(missing_docs)] pub fn get_dimension_type(&self) -> &::std::option::Option<crate::types::DimensionType> {
&self.dimension_type
}
#[allow(missing_docs)] pub fn value_compute_function_name(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
self.value_compute_function_name = ::std::option::Option::Some(input.into());
self
}
#[allow(missing_docs)] pub fn set_value_compute_function_name(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
self.value_compute_function_name = input; self
}
#[allow(missing_docs)] pub fn get_value_compute_function_name(&self) -> &::std::option::Option<::std::string::String> {
&self.value_compute_function_name
}
#[allow(missing_docs)] pub fn mandatory(mut self, input: bool) -> Self {
self.mandatory = ::std::option::Option::Some(input);
self
}
#[allow(missing_docs)] pub fn set_mandatory(mut self, input: ::std::option::Option<bool>) -> Self {
self.mandatory = input; self
}
#[allow(missing_docs)] pub fn get_mandatory(&self) -> &::std::option::Option<bool> {
&self.mandatory
}
pub fn build(self) -> ::std::result::Result<crate::operation::get_dimension::GetDimensionOutput, ::aws_smithy_types::error::operation::BuildError> {
::std::result::Result::Ok(
crate::operation::get_dimension::GetDimensionOutput {
dimension: self.dimension
.ok_or_else(||
::aws_smithy_types::error::operation::BuildError::missing_field("dimension", "dimension was not specified but it is required when building GetDimensionOutput")
)?
,
position: self.position
.ok_or_else(||
::aws_smithy_types::error::operation::BuildError::missing_field("position", "position was not specified but it is required when building GetDimensionOutput")
)?
,
schema: self.schema
.ok_or_else(||
::aws_smithy_types::error::operation::BuildError::missing_field("schema", "schema was not specified but it is required when building GetDimensionOutput")
)?
,
value_validation_function_name: self.value_validation_function_name
,
description: self.description
.ok_or_else(||
::aws_smithy_types::error::operation::BuildError::missing_field("description", "description was not specified but it is required when building GetDimensionOutput")
)?
,
change_reason: self.change_reason
.ok_or_else(||
::aws_smithy_types::error::operation::BuildError::missing_field("change_reason", "change_reason was not specified but it is required when building GetDimensionOutput")
)?
,
last_modified_at: self.last_modified_at
.ok_or_else(||
::aws_smithy_types::error::operation::BuildError::missing_field("last_modified_at", "last_modified_at was not specified but it is required when building GetDimensionOutput")
)?
,
last_modified_by: self.last_modified_by
.ok_or_else(||
::aws_smithy_types::error::operation::BuildError::missing_field("last_modified_by", "last_modified_by was not specified but it is required when building GetDimensionOutput")
)?
,
created_at: self.created_at
.ok_or_else(||
::aws_smithy_types::error::operation::BuildError::missing_field("created_at", "created_at was not specified but it is required when building GetDimensionOutput")
)?
,
created_by: self.created_by
.ok_or_else(||
::aws_smithy_types::error::operation::BuildError::missing_field("created_by", "created_by was not specified but it is required when building GetDimensionOutput")
)?
,
dependency_graph: self.dependency_graph
.ok_or_else(||
::aws_smithy_types::error::operation::BuildError::missing_field("dependency_graph", "dependency_graph was not specified but it is required when building GetDimensionOutput")
)?
,
dimension_type: self.dimension_type
.ok_or_else(||
::aws_smithy_types::error::operation::BuildError::missing_field("dimension_type", "dimension_type was not specified but it is required when building GetDimensionOutput")
)?
,
value_compute_function_name: self.value_compute_function_name
,
mandatory: self.mandatory
.ok_or_else(||
::aws_smithy_types::error::operation::BuildError::missing_field("mandatory", "mandatory was not specified but it is required when building GetDimensionOutput")
)?
,
}
)
}
}