aws_sdk_workspaces/operation/import_workspace_image/
_import_workspace_image_input.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 ImportWorkspaceImageInput {
6    /// <p>The identifier of the EC2 image.</p>
7    pub ec2_image_id: ::std::option::Option<::std::string::String>,
8    /// <p>The ingestion process to be used when importing the image, depending on which protocol you want to use for your BYOL Workspace image, either PCoIP, WSP, or bring your own protocol (BYOP). To use DCV, specify a value that ends in <code>_WSP</code>. To use PCoIP, specify a value that does not end in <code>_WSP</code>. To use BYOP, specify a value that ends in <code>_BYOP</code>.</p>
9    /// <p>For non-GPU-enabled bundles (bundles other than Graphics or GraphicsPro), specify <code>BYOL_REGULAR</code>, <code>BYOL_REGULAR_WSP</code>, or <code>BYOL_REGULAR_BYOP</code>, depending on the protocol.</p><note>
10    /// <p>The <code>BYOL_REGULAR_BYOP</code> and <code>BYOL_GRAPHICS_G4DN_BYOP</code> values are only supported by Amazon WorkSpaces Core. Contact your account team to be allow-listed to use these values. For more information, see <a href="http://aws.amazon.com/workspaces/core/">Amazon WorkSpaces Core</a>.</p>
11    /// </note>
12    pub ingestion_process: ::std::option::Option<crate::types::WorkspaceImageIngestionProcess>,
13    /// <p>The name of the WorkSpace image.</p>
14    pub image_name: ::std::option::Option<::std::string::String>,
15    /// <p>The description of the WorkSpace image.</p>
16    pub image_description: ::std::option::Option<::std::string::String>,
17    /// <p>The tags. Each WorkSpaces resource can have a maximum of 50 tags.</p>
18    pub tags: ::std::option::Option<::std::vec::Vec<crate::types::Tag>>,
19    /// <p>If specified, the version of Microsoft Office to subscribe to. Valid only for Windows 10 and 11 BYOL images. For more information about subscribing to Office for BYOL images, see <a href="https://docs.aws.amazon.com/workspaces/latest/adminguide/byol-windows-images.html"> Bring Your Own Windows Desktop Licenses</a>.</p><note>
20    /// <ul>
21    /// <li>
22    /// <p>Although this parameter is an array, only one item is allowed at this time.</p></li>
23    /// <li>
24    /// <p>During the image import process, non-GPU DCV (formerly WSP) WorkSpaces with Windows 11 support only <code>Microsoft_Office_2019</code>. GPU DCV (formerly WSP) WorkSpaces with Windows 11 do not support Office installation.</p></li>
25    /// </ul>
26    /// </note>
27    pub applications: ::std::option::Option<::std::vec::Vec<crate::types::Application>>,
28}
29impl ImportWorkspaceImageInput {
30    /// <p>The identifier of the EC2 image.</p>
31    pub fn ec2_image_id(&self) -> ::std::option::Option<&str> {
32        self.ec2_image_id.as_deref()
33    }
34    /// <p>The ingestion process to be used when importing the image, depending on which protocol you want to use for your BYOL Workspace image, either PCoIP, WSP, or bring your own protocol (BYOP). To use DCV, specify a value that ends in <code>_WSP</code>. To use PCoIP, specify a value that does not end in <code>_WSP</code>. To use BYOP, specify a value that ends in <code>_BYOP</code>.</p>
35    /// <p>For non-GPU-enabled bundles (bundles other than Graphics or GraphicsPro), specify <code>BYOL_REGULAR</code>, <code>BYOL_REGULAR_WSP</code>, or <code>BYOL_REGULAR_BYOP</code>, depending on the protocol.</p><note>
36    /// <p>The <code>BYOL_REGULAR_BYOP</code> and <code>BYOL_GRAPHICS_G4DN_BYOP</code> values are only supported by Amazon WorkSpaces Core. Contact your account team to be allow-listed to use these values. For more information, see <a href="http://aws.amazon.com/workspaces/core/">Amazon WorkSpaces Core</a>.</p>
37    /// </note>
38    pub fn ingestion_process(&self) -> ::std::option::Option<&crate::types::WorkspaceImageIngestionProcess> {
39        self.ingestion_process.as_ref()
40    }
41    /// <p>The name of the WorkSpace image.</p>
42    pub fn image_name(&self) -> ::std::option::Option<&str> {
43        self.image_name.as_deref()
44    }
45    /// <p>The description of the WorkSpace image.</p>
46    pub fn image_description(&self) -> ::std::option::Option<&str> {
47        self.image_description.as_deref()
48    }
49    /// <p>The tags. Each WorkSpaces resource can have a maximum of 50 tags.</p>
50    ///
51    /// If no value was sent for this field, a default will be set. If you want to determine if no value was sent, use `.tags.is_none()`.
52    pub fn tags(&self) -> &[crate::types::Tag] {
53        self.tags.as_deref().unwrap_or_default()
54    }
55    /// <p>If specified, the version of Microsoft Office to subscribe to. Valid only for Windows 10 and 11 BYOL images. For more information about subscribing to Office for BYOL images, see <a href="https://docs.aws.amazon.com/workspaces/latest/adminguide/byol-windows-images.html"> Bring Your Own Windows Desktop Licenses</a>.</p><note>
56    /// <ul>
57    /// <li>
58    /// <p>Although this parameter is an array, only one item is allowed at this time.</p></li>
59    /// <li>
60    /// <p>During the image import process, non-GPU DCV (formerly WSP) WorkSpaces with Windows 11 support only <code>Microsoft_Office_2019</code>. GPU DCV (formerly WSP) WorkSpaces with Windows 11 do not support Office installation.</p></li>
61    /// </ul>
62    /// </note>
63    ///
64    /// If no value was sent for this field, a default will be set. If you want to determine if no value was sent, use `.applications.is_none()`.
65    pub fn applications(&self) -> &[crate::types::Application] {
66        self.applications.as_deref().unwrap_or_default()
67    }
68}
69impl ImportWorkspaceImageInput {
70    /// Creates a new builder-style object to manufacture [`ImportWorkspaceImageInput`](crate::operation::import_workspace_image::ImportWorkspaceImageInput).
71    pub fn builder() -> crate::operation::import_workspace_image::builders::ImportWorkspaceImageInputBuilder {
72        crate::operation::import_workspace_image::builders::ImportWorkspaceImageInputBuilder::default()
73    }
74}
75
76/// A builder for [`ImportWorkspaceImageInput`](crate::operation::import_workspace_image::ImportWorkspaceImageInput).
77#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::default::Default, ::std::fmt::Debug)]
78#[non_exhaustive]
79pub struct ImportWorkspaceImageInputBuilder {
80    pub(crate) ec2_image_id: ::std::option::Option<::std::string::String>,
81    pub(crate) ingestion_process: ::std::option::Option<crate::types::WorkspaceImageIngestionProcess>,
82    pub(crate) image_name: ::std::option::Option<::std::string::String>,
83    pub(crate) image_description: ::std::option::Option<::std::string::String>,
84    pub(crate) tags: ::std::option::Option<::std::vec::Vec<crate::types::Tag>>,
85    pub(crate) applications: ::std::option::Option<::std::vec::Vec<crate::types::Application>>,
86}
87impl ImportWorkspaceImageInputBuilder {
88    /// <p>The identifier of the EC2 image.</p>
89    /// This field is required.
90    pub fn ec2_image_id(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
91        self.ec2_image_id = ::std::option::Option::Some(input.into());
92        self
93    }
94    /// <p>The identifier of the EC2 image.</p>
95    pub fn set_ec2_image_id(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
96        self.ec2_image_id = input;
97        self
98    }
99    /// <p>The identifier of the EC2 image.</p>
100    pub fn get_ec2_image_id(&self) -> &::std::option::Option<::std::string::String> {
101        &self.ec2_image_id
102    }
103    /// <p>The ingestion process to be used when importing the image, depending on which protocol you want to use for your BYOL Workspace image, either PCoIP, WSP, or bring your own protocol (BYOP). To use DCV, specify a value that ends in <code>_WSP</code>. To use PCoIP, specify a value that does not end in <code>_WSP</code>. To use BYOP, specify a value that ends in <code>_BYOP</code>.</p>
104    /// <p>For non-GPU-enabled bundles (bundles other than Graphics or GraphicsPro), specify <code>BYOL_REGULAR</code>, <code>BYOL_REGULAR_WSP</code>, or <code>BYOL_REGULAR_BYOP</code>, depending on the protocol.</p><note>
105    /// <p>The <code>BYOL_REGULAR_BYOP</code> and <code>BYOL_GRAPHICS_G4DN_BYOP</code> values are only supported by Amazon WorkSpaces Core. Contact your account team to be allow-listed to use these values. For more information, see <a href="http://aws.amazon.com/workspaces/core/">Amazon WorkSpaces Core</a>.</p>
106    /// </note>
107    /// This field is required.
108    pub fn ingestion_process(mut self, input: crate::types::WorkspaceImageIngestionProcess) -> Self {
109        self.ingestion_process = ::std::option::Option::Some(input);
110        self
111    }
112    /// <p>The ingestion process to be used when importing the image, depending on which protocol you want to use for your BYOL Workspace image, either PCoIP, WSP, or bring your own protocol (BYOP). To use DCV, specify a value that ends in <code>_WSP</code>. To use PCoIP, specify a value that does not end in <code>_WSP</code>. To use BYOP, specify a value that ends in <code>_BYOP</code>.</p>
113    /// <p>For non-GPU-enabled bundles (bundles other than Graphics or GraphicsPro), specify <code>BYOL_REGULAR</code>, <code>BYOL_REGULAR_WSP</code>, or <code>BYOL_REGULAR_BYOP</code>, depending on the protocol.</p><note>
114    /// <p>The <code>BYOL_REGULAR_BYOP</code> and <code>BYOL_GRAPHICS_G4DN_BYOP</code> values are only supported by Amazon WorkSpaces Core. Contact your account team to be allow-listed to use these values. For more information, see <a href="http://aws.amazon.com/workspaces/core/">Amazon WorkSpaces Core</a>.</p>
115    /// </note>
116    pub fn set_ingestion_process(mut self, input: ::std::option::Option<crate::types::WorkspaceImageIngestionProcess>) -> Self {
117        self.ingestion_process = input;
118        self
119    }
120    /// <p>The ingestion process to be used when importing the image, depending on which protocol you want to use for your BYOL Workspace image, either PCoIP, WSP, or bring your own protocol (BYOP). To use DCV, specify a value that ends in <code>_WSP</code>. To use PCoIP, specify a value that does not end in <code>_WSP</code>. To use BYOP, specify a value that ends in <code>_BYOP</code>.</p>
121    /// <p>For non-GPU-enabled bundles (bundles other than Graphics or GraphicsPro), specify <code>BYOL_REGULAR</code>, <code>BYOL_REGULAR_WSP</code>, or <code>BYOL_REGULAR_BYOP</code>, depending on the protocol.</p><note>
122    /// <p>The <code>BYOL_REGULAR_BYOP</code> and <code>BYOL_GRAPHICS_G4DN_BYOP</code> values are only supported by Amazon WorkSpaces Core. Contact your account team to be allow-listed to use these values. For more information, see <a href="http://aws.amazon.com/workspaces/core/">Amazon WorkSpaces Core</a>.</p>
123    /// </note>
124    pub fn get_ingestion_process(&self) -> &::std::option::Option<crate::types::WorkspaceImageIngestionProcess> {
125        &self.ingestion_process
126    }
127    /// <p>The name of the WorkSpace image.</p>
128    /// This field is required.
129    pub fn image_name(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
130        self.image_name = ::std::option::Option::Some(input.into());
131        self
132    }
133    /// <p>The name of the WorkSpace image.</p>
134    pub fn set_image_name(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
135        self.image_name = input;
136        self
137    }
138    /// <p>The name of the WorkSpace image.</p>
139    pub fn get_image_name(&self) -> &::std::option::Option<::std::string::String> {
140        &self.image_name
141    }
142    /// <p>The description of the WorkSpace image.</p>
143    /// This field is required.
144    pub fn image_description(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
145        self.image_description = ::std::option::Option::Some(input.into());
146        self
147    }
148    /// <p>The description of the WorkSpace image.</p>
149    pub fn set_image_description(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
150        self.image_description = input;
151        self
152    }
153    /// <p>The description of the WorkSpace image.</p>
154    pub fn get_image_description(&self) -> &::std::option::Option<::std::string::String> {
155        &self.image_description
156    }
157    /// Appends an item to `tags`.
158    ///
159    /// To override the contents of this collection use [`set_tags`](Self::set_tags).
160    ///
161    /// <p>The tags. Each WorkSpaces resource can have a maximum of 50 tags.</p>
162    pub fn tags(mut self, input: crate::types::Tag) -> Self {
163        let mut v = self.tags.unwrap_or_default();
164        v.push(input);
165        self.tags = ::std::option::Option::Some(v);
166        self
167    }
168    /// <p>The tags. Each WorkSpaces resource can have a maximum of 50 tags.</p>
169    pub fn set_tags(mut self, input: ::std::option::Option<::std::vec::Vec<crate::types::Tag>>) -> Self {
170        self.tags = input;
171        self
172    }
173    /// <p>The tags. Each WorkSpaces resource can have a maximum of 50 tags.</p>
174    pub fn get_tags(&self) -> &::std::option::Option<::std::vec::Vec<crate::types::Tag>> {
175        &self.tags
176    }
177    /// Appends an item to `applications`.
178    ///
179    /// To override the contents of this collection use [`set_applications`](Self::set_applications).
180    ///
181    /// <p>If specified, the version of Microsoft Office to subscribe to. Valid only for Windows 10 and 11 BYOL images. For more information about subscribing to Office for BYOL images, see <a href="https://docs.aws.amazon.com/workspaces/latest/adminguide/byol-windows-images.html"> Bring Your Own Windows Desktop Licenses</a>.</p><note>
182    /// <ul>
183    /// <li>
184    /// <p>Although this parameter is an array, only one item is allowed at this time.</p></li>
185    /// <li>
186    /// <p>During the image import process, non-GPU DCV (formerly WSP) WorkSpaces with Windows 11 support only <code>Microsoft_Office_2019</code>. GPU DCV (formerly WSP) WorkSpaces with Windows 11 do not support Office installation.</p></li>
187    /// </ul>
188    /// </note>
189    pub fn applications(mut self, input: crate::types::Application) -> Self {
190        let mut v = self.applications.unwrap_or_default();
191        v.push(input);
192        self.applications = ::std::option::Option::Some(v);
193        self
194    }
195    /// <p>If specified, the version of Microsoft Office to subscribe to. Valid only for Windows 10 and 11 BYOL images. For more information about subscribing to Office for BYOL images, see <a href="https://docs.aws.amazon.com/workspaces/latest/adminguide/byol-windows-images.html"> Bring Your Own Windows Desktop Licenses</a>.</p><note>
196    /// <ul>
197    /// <li>
198    /// <p>Although this parameter is an array, only one item is allowed at this time.</p></li>
199    /// <li>
200    /// <p>During the image import process, non-GPU DCV (formerly WSP) WorkSpaces with Windows 11 support only <code>Microsoft_Office_2019</code>. GPU DCV (formerly WSP) WorkSpaces with Windows 11 do not support Office installation.</p></li>
201    /// </ul>
202    /// </note>
203    pub fn set_applications(mut self, input: ::std::option::Option<::std::vec::Vec<crate::types::Application>>) -> Self {
204        self.applications = input;
205        self
206    }
207    /// <p>If specified, the version of Microsoft Office to subscribe to. Valid only for Windows 10 and 11 BYOL images. For more information about subscribing to Office for BYOL images, see <a href="https://docs.aws.amazon.com/workspaces/latest/adminguide/byol-windows-images.html"> Bring Your Own Windows Desktop Licenses</a>.</p><note>
208    /// <ul>
209    /// <li>
210    /// <p>Although this parameter is an array, only one item is allowed at this time.</p></li>
211    /// <li>
212    /// <p>During the image import process, non-GPU DCV (formerly WSP) WorkSpaces with Windows 11 support only <code>Microsoft_Office_2019</code>. GPU DCV (formerly WSP) WorkSpaces with Windows 11 do not support Office installation.</p></li>
213    /// </ul>
214    /// </note>
215    pub fn get_applications(&self) -> &::std::option::Option<::std::vec::Vec<crate::types::Application>> {
216        &self.applications
217    }
218    /// Consumes the builder and constructs a [`ImportWorkspaceImageInput`](crate::operation::import_workspace_image::ImportWorkspaceImageInput).
219    pub fn build(
220        self,
221    ) -> ::std::result::Result<crate::operation::import_workspace_image::ImportWorkspaceImageInput, ::aws_smithy_types::error::operation::BuildError>
222    {
223        ::std::result::Result::Ok(crate::operation::import_workspace_image::ImportWorkspaceImageInput {
224            ec2_image_id: self.ec2_image_id,
225            ingestion_process: self.ingestion_process,
226            image_name: self.image_name,
227            image_description: self.image_description,
228            tags: self.tags,
229            applications: self.applications,
230        })
231    }
232}