aws_sdk_imagebuilder/operation/create_image/
_create_image_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 CreateImageOutput {
6    /// <p>The request ID that uniquely identifies this request.</p>
7    pub request_id: ::std::option::Option<::std::string::String>,
8    /// <p>The client token that uniquely identifies the request.</p>
9    pub client_token: ::std::option::Option<::std::string::String>,
10    /// <p>The Amazon Resource Name (ARN) of the image that the request created.</p>
11    pub image_build_version_arn: ::std::option::Option<::std::string::String>,
12    /// <p>The resource ARNs with different wildcard variations of semantic versioning.</p>
13    pub latest_version_references: ::std::option::Option<crate::types::LatestVersionReferences>,
14    _request_id: Option<String>,
15}
16impl CreateImageOutput {
17    /// <p>The request ID that uniquely identifies this request.</p>
18    pub fn request_id(&self) -> ::std::option::Option<&str> {
19        self.request_id.as_deref()
20    }
21    /// <p>The client token that uniquely identifies the request.</p>
22    pub fn client_token(&self) -> ::std::option::Option<&str> {
23        self.client_token.as_deref()
24    }
25    /// <p>The Amazon Resource Name (ARN) of the image that the request created.</p>
26    pub fn image_build_version_arn(&self) -> ::std::option::Option<&str> {
27        self.image_build_version_arn.as_deref()
28    }
29    /// <p>The resource ARNs with different wildcard variations of semantic versioning.</p>
30    pub fn latest_version_references(&self) -> ::std::option::Option<&crate::types::LatestVersionReferences> {
31        self.latest_version_references.as_ref()
32    }
33}
34impl ::aws_types::request_id::RequestId for CreateImageOutput {
35    fn request_id(&self) -> Option<&str> {
36        self._request_id.as_deref()
37    }
38}
39impl CreateImageOutput {
40    /// Creates a new builder-style object to manufacture [`CreateImageOutput`](crate::operation::create_image::CreateImageOutput).
41    pub fn builder() -> crate::operation::create_image::builders::CreateImageOutputBuilder {
42        crate::operation::create_image::builders::CreateImageOutputBuilder::default()
43    }
44}
45
46/// A builder for [`CreateImageOutput`](crate::operation::create_image::CreateImageOutput).
47#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::default::Default, ::std::fmt::Debug)]
48#[non_exhaustive]
49pub struct CreateImageOutputBuilder {
50    pub(crate) request_id: ::std::option::Option<::std::string::String>,
51    pub(crate) client_token: ::std::option::Option<::std::string::String>,
52    pub(crate) image_build_version_arn: ::std::option::Option<::std::string::String>,
53    pub(crate) latest_version_references: ::std::option::Option<crate::types::LatestVersionReferences>,
54    _request_id: Option<String>,
55}
56impl CreateImageOutputBuilder {
57    /// <p>The request ID that uniquely identifies this request.</p>
58    pub fn request_id(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
59        self.request_id = ::std::option::Option::Some(input.into());
60        self
61    }
62    /// <p>The request ID that uniquely identifies this request.</p>
63    pub fn set_request_id(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
64        self.request_id = input;
65        self
66    }
67    /// <p>The request ID that uniquely identifies this request.</p>
68    pub fn get_request_id(&self) -> &::std::option::Option<::std::string::String> {
69        &self.request_id
70    }
71    /// <p>The client token that uniquely identifies the request.</p>
72    pub fn client_token(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
73        self.client_token = ::std::option::Option::Some(input.into());
74        self
75    }
76    /// <p>The client token that uniquely identifies the request.</p>
77    pub fn set_client_token(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
78        self.client_token = input;
79        self
80    }
81    /// <p>The client token that uniquely identifies the request.</p>
82    pub fn get_client_token(&self) -> &::std::option::Option<::std::string::String> {
83        &self.client_token
84    }
85    /// <p>The Amazon Resource Name (ARN) of the image that the request created.</p>
86    pub fn image_build_version_arn(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
87        self.image_build_version_arn = ::std::option::Option::Some(input.into());
88        self
89    }
90    /// <p>The Amazon Resource Name (ARN) of the image that the request created.</p>
91    pub fn set_image_build_version_arn(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
92        self.image_build_version_arn = input;
93        self
94    }
95    /// <p>The Amazon Resource Name (ARN) of the image that the request created.</p>
96    pub fn get_image_build_version_arn(&self) -> &::std::option::Option<::std::string::String> {
97        &self.image_build_version_arn
98    }
99    /// <p>The resource ARNs with different wildcard variations of semantic versioning.</p>
100    pub fn latest_version_references(mut self, input: crate::types::LatestVersionReferences) -> Self {
101        self.latest_version_references = ::std::option::Option::Some(input);
102        self
103    }
104    /// <p>The resource ARNs with different wildcard variations of semantic versioning.</p>
105    pub fn set_latest_version_references(mut self, input: ::std::option::Option<crate::types::LatestVersionReferences>) -> Self {
106        self.latest_version_references = input;
107        self
108    }
109    /// <p>The resource ARNs with different wildcard variations of semantic versioning.</p>
110    pub fn get_latest_version_references(&self) -> &::std::option::Option<crate::types::LatestVersionReferences> {
111        &self.latest_version_references
112    }
113    pub(crate) fn _request_id(mut self, request_id: impl Into<String>) -> Self {
114        self._request_id = Some(request_id.into());
115        self
116    }
117
118    pub(crate) fn _set_request_id(&mut self, request_id: Option<String>) -> &mut Self {
119        self._request_id = request_id;
120        self
121    }
122    /// Consumes the builder and constructs a [`CreateImageOutput`](crate::operation::create_image::CreateImageOutput).
123    pub fn build(self) -> crate::operation::create_image::CreateImageOutput {
124        crate::operation::create_image::CreateImageOutput {
125            request_id: self.request_id,
126            client_token: self.client_token,
127            image_build_version_arn: self.image_build_version_arn,
128            latest_version_references: self.latest_version_references,
129            _request_id: self._request_id,
130        }
131    }
132}