aws_sdk_greengrass/operation/get_group/
_get_group_output.rs1#[allow(missing_docs)] #[non_exhaustive]
4#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::fmt::Debug)]
5pub struct GetGroupOutput {
6 pub arn: ::std::option::Option<::std::string::String>,
8 pub creation_timestamp: ::std::option::Option<::std::string::String>,
10 pub id: ::std::option::Option<::std::string::String>,
12 pub last_updated_timestamp: ::std::option::Option<::std::string::String>,
14 pub latest_version: ::std::option::Option<::std::string::String>,
16 pub latest_version_arn: ::std::option::Option<::std::string::String>,
18 pub name: ::std::option::Option<::std::string::String>,
20 pub tags: ::std::option::Option<::std::collections::HashMap<::std::string::String, ::std::string::String>>,
22 _request_id: Option<String>,
23}
24impl GetGroupOutput {
25 pub fn arn(&self) -> ::std::option::Option<&str> {
27 self.arn.as_deref()
28 }
29 pub fn creation_timestamp(&self) -> ::std::option::Option<&str> {
31 self.creation_timestamp.as_deref()
32 }
33 pub fn id(&self) -> ::std::option::Option<&str> {
35 self.id.as_deref()
36 }
37 pub fn last_updated_timestamp(&self) -> ::std::option::Option<&str> {
39 self.last_updated_timestamp.as_deref()
40 }
41 pub fn latest_version(&self) -> ::std::option::Option<&str> {
43 self.latest_version.as_deref()
44 }
45 pub fn latest_version_arn(&self) -> ::std::option::Option<&str> {
47 self.latest_version_arn.as_deref()
48 }
49 pub fn name(&self) -> ::std::option::Option<&str> {
51 self.name.as_deref()
52 }
53 pub fn tags(&self) -> ::std::option::Option<&::std::collections::HashMap<::std::string::String, ::std::string::String>> {
55 self.tags.as_ref()
56 }
57}
58impl ::aws_types::request_id::RequestId for GetGroupOutput {
59 fn request_id(&self) -> Option<&str> {
60 self._request_id.as_deref()
61 }
62}
63impl GetGroupOutput {
64 pub fn builder() -> crate::operation::get_group::builders::GetGroupOutputBuilder {
66 crate::operation::get_group::builders::GetGroupOutputBuilder::default()
67 }
68}
69
70#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::default::Default, ::std::fmt::Debug)]
72#[non_exhaustive]
73pub struct GetGroupOutputBuilder {
74 pub(crate) arn: ::std::option::Option<::std::string::String>,
75 pub(crate) creation_timestamp: ::std::option::Option<::std::string::String>,
76 pub(crate) id: ::std::option::Option<::std::string::String>,
77 pub(crate) last_updated_timestamp: ::std::option::Option<::std::string::String>,
78 pub(crate) latest_version: ::std::option::Option<::std::string::String>,
79 pub(crate) latest_version_arn: ::std::option::Option<::std::string::String>,
80 pub(crate) name: ::std::option::Option<::std::string::String>,
81 pub(crate) tags: ::std::option::Option<::std::collections::HashMap<::std::string::String, ::std::string::String>>,
82 _request_id: Option<String>,
83}
84impl GetGroupOutputBuilder {
85 pub fn arn(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
87 self.arn = ::std::option::Option::Some(input.into());
88 self
89 }
90 pub fn set_arn(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
92 self.arn = input;
93 self
94 }
95 pub fn get_arn(&self) -> &::std::option::Option<::std::string::String> {
97 &self.arn
98 }
99 pub fn creation_timestamp(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
101 self.creation_timestamp = ::std::option::Option::Some(input.into());
102 self
103 }
104 pub fn set_creation_timestamp(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
106 self.creation_timestamp = input;
107 self
108 }
109 pub fn get_creation_timestamp(&self) -> &::std::option::Option<::std::string::String> {
111 &self.creation_timestamp
112 }
113 pub fn id(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
115 self.id = ::std::option::Option::Some(input.into());
116 self
117 }
118 pub fn set_id(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
120 self.id = input;
121 self
122 }
123 pub fn get_id(&self) -> &::std::option::Option<::std::string::String> {
125 &self.id
126 }
127 pub fn last_updated_timestamp(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
129 self.last_updated_timestamp = ::std::option::Option::Some(input.into());
130 self
131 }
132 pub fn set_last_updated_timestamp(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
134 self.last_updated_timestamp = input;
135 self
136 }
137 pub fn get_last_updated_timestamp(&self) -> &::std::option::Option<::std::string::String> {
139 &self.last_updated_timestamp
140 }
141 pub fn latest_version(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
143 self.latest_version = ::std::option::Option::Some(input.into());
144 self
145 }
146 pub fn set_latest_version(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
148 self.latest_version = input;
149 self
150 }
151 pub fn get_latest_version(&self) -> &::std::option::Option<::std::string::String> {
153 &self.latest_version
154 }
155 pub fn latest_version_arn(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
157 self.latest_version_arn = ::std::option::Option::Some(input.into());
158 self
159 }
160 pub fn set_latest_version_arn(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
162 self.latest_version_arn = input;
163 self
164 }
165 pub fn get_latest_version_arn(&self) -> &::std::option::Option<::std::string::String> {
167 &self.latest_version_arn
168 }
169 pub fn name(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
171 self.name = ::std::option::Option::Some(input.into());
172 self
173 }
174 pub fn set_name(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
176 self.name = input;
177 self
178 }
179 pub fn get_name(&self) -> &::std::option::Option<::std::string::String> {
181 &self.name
182 }
183 pub fn tags(mut self, k: impl ::std::convert::Into<::std::string::String>, v: impl ::std::convert::Into<::std::string::String>) -> Self {
189 let mut hash_map = self.tags.unwrap_or_default();
190 hash_map.insert(k.into(), v.into());
191 self.tags = ::std::option::Option::Some(hash_map);
192 self
193 }
194 pub fn set_tags(mut self, input: ::std::option::Option<::std::collections::HashMap<::std::string::String, ::std::string::String>>) -> Self {
196 self.tags = input;
197 self
198 }
199 pub fn get_tags(&self) -> &::std::option::Option<::std::collections::HashMap<::std::string::String, ::std::string::String>> {
201 &self.tags
202 }
203 pub(crate) fn _request_id(mut self, request_id: impl Into<String>) -> Self {
204 self._request_id = Some(request_id.into());
205 self
206 }
207
208 pub(crate) fn _set_request_id(&mut self, request_id: Option<String>) -> &mut Self {
209 self._request_id = request_id;
210 self
211 }
212 pub fn build(self) -> crate::operation::get_group::GetGroupOutput {
214 crate::operation::get_group::GetGroupOutput {
215 arn: self.arn,
216 creation_timestamp: self.creation_timestamp,
217 id: self.id,
218 last_updated_timestamp: self.last_updated_timestamp,
219 latest_version: self.latest_version,
220 latest_version_arn: self.latest_version_arn,
221 name: self.name,
222 tags: self.tags,
223 _request_id: self._request_id,
224 }
225 }
226}