aws_sdk_quicksight/operation/create_group/
_create_group_input.rs1#[non_exhaustive]
5#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::fmt::Debug)]
6pub struct CreateGroupInput {
7 pub group_name: ::std::option::Option<::std::string::String>,
9 pub description: ::std::option::Option<::std::string::String>,
11 pub aws_account_id: ::std::option::Option<::std::string::String>,
13 pub namespace: ::std::option::Option<::std::string::String>,
15}
16impl CreateGroupInput {
17 pub fn group_name(&self) -> ::std::option::Option<&str> {
19 self.group_name.as_deref()
20 }
21 pub fn description(&self) -> ::std::option::Option<&str> {
23 self.description.as_deref()
24 }
25 pub fn aws_account_id(&self) -> ::std::option::Option<&str> {
27 self.aws_account_id.as_deref()
28 }
29 pub fn namespace(&self) -> ::std::option::Option<&str> {
31 self.namespace.as_deref()
32 }
33}
34impl CreateGroupInput {
35 pub fn builder() -> crate::operation::create_group::builders::CreateGroupInputBuilder {
37 crate::operation::create_group::builders::CreateGroupInputBuilder::default()
38 }
39}
40
41#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::default::Default, ::std::fmt::Debug)]
43#[non_exhaustive]
44pub struct CreateGroupInputBuilder {
45 pub(crate) group_name: ::std::option::Option<::std::string::String>,
46 pub(crate) description: ::std::option::Option<::std::string::String>,
47 pub(crate) aws_account_id: ::std::option::Option<::std::string::String>,
48 pub(crate) namespace: ::std::option::Option<::std::string::String>,
49}
50impl CreateGroupInputBuilder {
51 pub fn group_name(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
54 self.group_name = ::std::option::Option::Some(input.into());
55 self
56 }
57 pub fn set_group_name(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
59 self.group_name = input;
60 self
61 }
62 pub fn get_group_name(&self) -> &::std::option::Option<::std::string::String> {
64 &self.group_name
65 }
66 pub fn description(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
68 self.description = ::std::option::Option::Some(input.into());
69 self
70 }
71 pub fn set_description(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
73 self.description = input;
74 self
75 }
76 pub fn get_description(&self) -> &::std::option::Option<::std::string::String> {
78 &self.description
79 }
80 pub fn aws_account_id(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
83 self.aws_account_id = ::std::option::Option::Some(input.into());
84 self
85 }
86 pub fn set_aws_account_id(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
88 self.aws_account_id = input;
89 self
90 }
91 pub fn get_aws_account_id(&self) -> &::std::option::Option<::std::string::String> {
93 &self.aws_account_id
94 }
95 pub fn namespace(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
98 self.namespace = ::std::option::Option::Some(input.into());
99 self
100 }
101 pub fn set_namespace(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
103 self.namespace = input;
104 self
105 }
106 pub fn get_namespace(&self) -> &::std::option::Option<::std::string::String> {
108 &self.namespace
109 }
110 pub fn build(self) -> ::std::result::Result<crate::operation::create_group::CreateGroupInput, ::aws_smithy_types::error::operation::BuildError> {
112 ::std::result::Result::Ok(crate::operation::create_group::CreateGroupInput {
113 group_name: self.group_name,
114 description: self.description,
115 aws_account_id: self.aws_account_id,
116 namespace: self.namespace,
117 })
118 }
119}