aws_sdk_greengrass/operation/create_group/
_create_group_output.rs

1// Code generated by software.amazon.smithy.rust.codegen.smithy-rs. DO NOT EDIT.
2#[allow(missing_docs)] // documentation missing in model
3#[non_exhaustive]
4#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::fmt::Debug)]
5pub struct CreateGroupOutput {
6    /// The ARN of the definition.
7    pub arn: ::std::option::Option<::std::string::String>,
8    /// The time, in milliseconds since the epoch, when the definition was created.
9    pub creation_timestamp: ::std::option::Option<::std::string::String>,
10    /// The ID of the definition.
11    pub id: ::std::option::Option<::std::string::String>,
12    /// The time, in milliseconds since the epoch, when the definition was last updated.
13    pub last_updated_timestamp: ::std::option::Option<::std::string::String>,
14    /// The ID of the latest version associated with the definition.
15    pub latest_version: ::std::option::Option<::std::string::String>,
16    /// The ARN of the latest version associated with the definition.
17    pub latest_version_arn: ::std::option::Option<::std::string::String>,
18    /// The name of the definition.
19    pub name: ::std::option::Option<::std::string::String>,
20    _request_id: Option<String>,
21}
22impl CreateGroupOutput {
23    /// The ARN of the definition.
24    pub fn arn(&self) -> ::std::option::Option<&str> {
25        self.arn.as_deref()
26    }
27    /// The time, in milliseconds since the epoch, when the definition was created.
28    pub fn creation_timestamp(&self) -> ::std::option::Option<&str> {
29        self.creation_timestamp.as_deref()
30    }
31    /// The ID of the definition.
32    pub fn id(&self) -> ::std::option::Option<&str> {
33        self.id.as_deref()
34    }
35    /// The time, in milliseconds since the epoch, when the definition was last updated.
36    pub fn last_updated_timestamp(&self) -> ::std::option::Option<&str> {
37        self.last_updated_timestamp.as_deref()
38    }
39    /// The ID of the latest version associated with the definition.
40    pub fn latest_version(&self) -> ::std::option::Option<&str> {
41        self.latest_version.as_deref()
42    }
43    /// The ARN of the latest version associated with the definition.
44    pub fn latest_version_arn(&self) -> ::std::option::Option<&str> {
45        self.latest_version_arn.as_deref()
46    }
47    /// The name of the definition.
48    pub fn name(&self) -> ::std::option::Option<&str> {
49        self.name.as_deref()
50    }
51}
52impl ::aws_types::request_id::RequestId for CreateGroupOutput {
53    fn request_id(&self) -> Option<&str> {
54        self._request_id.as_deref()
55    }
56}
57impl CreateGroupOutput {
58    /// Creates a new builder-style object to manufacture [`CreateGroupOutput`](crate::operation::create_group::CreateGroupOutput).
59    pub fn builder() -> crate::operation::create_group::builders::CreateGroupOutputBuilder {
60        crate::operation::create_group::builders::CreateGroupOutputBuilder::default()
61    }
62}
63
64/// A builder for [`CreateGroupOutput`](crate::operation::create_group::CreateGroupOutput).
65#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::default::Default, ::std::fmt::Debug)]
66#[non_exhaustive]
67pub struct CreateGroupOutputBuilder {
68    pub(crate) arn: ::std::option::Option<::std::string::String>,
69    pub(crate) creation_timestamp: ::std::option::Option<::std::string::String>,
70    pub(crate) id: ::std::option::Option<::std::string::String>,
71    pub(crate) last_updated_timestamp: ::std::option::Option<::std::string::String>,
72    pub(crate) latest_version: ::std::option::Option<::std::string::String>,
73    pub(crate) latest_version_arn: ::std::option::Option<::std::string::String>,
74    pub(crate) name: ::std::option::Option<::std::string::String>,
75    _request_id: Option<String>,
76}
77impl CreateGroupOutputBuilder {
78    /// The ARN of the definition.
79    pub fn arn(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
80        self.arn = ::std::option::Option::Some(input.into());
81        self
82    }
83    /// The ARN of the definition.
84    pub fn set_arn(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
85        self.arn = input;
86        self
87    }
88    /// The ARN of the definition.
89    pub fn get_arn(&self) -> &::std::option::Option<::std::string::String> {
90        &self.arn
91    }
92    /// The time, in milliseconds since the epoch, when the definition was created.
93    pub fn creation_timestamp(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
94        self.creation_timestamp = ::std::option::Option::Some(input.into());
95        self
96    }
97    /// The time, in milliseconds since the epoch, when the definition was created.
98    pub fn set_creation_timestamp(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
99        self.creation_timestamp = input;
100        self
101    }
102    /// The time, in milliseconds since the epoch, when the definition was created.
103    pub fn get_creation_timestamp(&self) -> &::std::option::Option<::std::string::String> {
104        &self.creation_timestamp
105    }
106    /// The ID of the definition.
107    pub fn id(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
108        self.id = ::std::option::Option::Some(input.into());
109        self
110    }
111    /// The ID of the definition.
112    pub fn set_id(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
113        self.id = input;
114        self
115    }
116    /// The ID of the definition.
117    pub fn get_id(&self) -> &::std::option::Option<::std::string::String> {
118        &self.id
119    }
120    /// The time, in milliseconds since the epoch, when the definition was last updated.
121    pub fn last_updated_timestamp(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
122        self.last_updated_timestamp = ::std::option::Option::Some(input.into());
123        self
124    }
125    /// The time, in milliseconds since the epoch, when the definition was last updated.
126    pub fn set_last_updated_timestamp(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
127        self.last_updated_timestamp = input;
128        self
129    }
130    /// The time, in milliseconds since the epoch, when the definition was last updated.
131    pub fn get_last_updated_timestamp(&self) -> &::std::option::Option<::std::string::String> {
132        &self.last_updated_timestamp
133    }
134    /// The ID of the latest version associated with the definition.
135    pub fn latest_version(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
136        self.latest_version = ::std::option::Option::Some(input.into());
137        self
138    }
139    /// The ID of the latest version associated with the definition.
140    pub fn set_latest_version(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
141        self.latest_version = input;
142        self
143    }
144    /// The ID of the latest version associated with the definition.
145    pub fn get_latest_version(&self) -> &::std::option::Option<::std::string::String> {
146        &self.latest_version
147    }
148    /// The ARN of the latest version associated with the definition.
149    pub fn latest_version_arn(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
150        self.latest_version_arn = ::std::option::Option::Some(input.into());
151        self
152    }
153    /// The ARN of the latest version associated with the definition.
154    pub fn set_latest_version_arn(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
155        self.latest_version_arn = input;
156        self
157    }
158    /// The ARN of the latest version associated with the definition.
159    pub fn get_latest_version_arn(&self) -> &::std::option::Option<::std::string::String> {
160        &self.latest_version_arn
161    }
162    /// The name of the definition.
163    pub fn name(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
164        self.name = ::std::option::Option::Some(input.into());
165        self
166    }
167    /// The name of the definition.
168    pub fn set_name(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
169        self.name = input;
170        self
171    }
172    /// The name of the definition.
173    pub fn get_name(&self) -> &::std::option::Option<::std::string::String> {
174        &self.name
175    }
176    pub(crate) fn _request_id(mut self, request_id: impl Into<String>) -> Self {
177        self._request_id = Some(request_id.into());
178        self
179    }
180
181    pub(crate) fn _set_request_id(&mut self, request_id: Option<String>) -> &mut Self {
182        self._request_id = request_id;
183        self
184    }
185    /// Consumes the builder and constructs a [`CreateGroupOutput`](crate::operation::create_group::CreateGroupOutput).
186    pub fn build(self) -> crate::operation::create_group::CreateGroupOutput {
187        crate::operation::create_group::CreateGroupOutput {
188            arn: self.arn,
189            creation_timestamp: self.creation_timestamp,
190            id: self.id,
191            last_updated_timestamp: self.last_updated_timestamp,
192            latest_version: self.latest_version,
193            latest_version_arn: self.latest_version_arn,
194            name: self.name,
195            _request_id: self._request_id,
196        }
197    }
198}