cfn/aws/
batch.rs

1//! Types for the `Batch` service.
2
3/// The [`AWS::Batch::ComputeEnvironment`](http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-batch-computeenvironment.html) resource type.
4#[derive(Debug, Default)]
5pub struct ComputeEnvironment {
6    properties: ComputeEnvironmentProperties
7}
8
9/// Properties for the `ComputeEnvironment` resource.
10#[derive(Debug, Default)]
11pub struct ComputeEnvironmentProperties {
12    /// Property [`ComputeEnvironmentName`](http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-batch-computeenvironment.html#cfn-batch-computeenvironment-computeenvironmentname).
13    ///
14    /// Update type: _Immutable_.
15    /// AWS CloudFormation replaces the resource when you change this property.
16    pub compute_environment_name: Option<::Value<String>>,
17    /// Property [`ComputeResources`](http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-batch-computeenvironment.html#cfn-batch-computeenvironment-computeresources).
18    ///
19    /// Update type: _Mutable_.
20    /// AWS CloudFormation doesn't replace the resource when you change this property.
21    pub compute_resources: Option<::Value<self::compute_environment::ComputeResources>>,
22    /// Property [`ServiceRole`](http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-batch-computeenvironment.html#cfn-batch-computeenvironment-servicerole).
23    ///
24    /// Update type: _Mutable_.
25    /// AWS CloudFormation doesn't replace the resource when you change this property.
26    pub service_role: Option<::Value<String>>,
27    /// Property [`State`](http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-batch-computeenvironment.html#cfn-batch-computeenvironment-state).
28    ///
29    /// Update type: _Mutable_.
30    /// AWS CloudFormation doesn't replace the resource when you change this property.
31    pub state: Option<::Value<String>>,
32    /// Property [`Tags`](http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-batch-computeenvironment.html#cfn-batch-computeenvironment-tags).
33    ///
34    /// Update type: _Immutable_.
35    /// AWS CloudFormation replaces the resource when you change this property.
36    pub tags: Option<::Value<::json::Value>>,
37    /// Property [`Type`](http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-batch-computeenvironment.html#cfn-batch-computeenvironment-type).
38    ///
39    /// Update type: _Immutable_.
40    /// AWS CloudFormation replaces the resource when you change this property.
41    pub r#type: ::Value<String>,
42}
43
44impl ::serde::Serialize for ComputeEnvironmentProperties {
45    fn serialize<S: ::serde::Serializer>(&self, s: S) -> Result<S::Ok, S::Error> {
46        let mut map = ::serde::Serializer::serialize_map(s, None)?;
47        if let Some(ref compute_environment_name) = self.compute_environment_name {
48            ::serde::ser::SerializeMap::serialize_entry(&mut map, "ComputeEnvironmentName", compute_environment_name)?;
49        }
50        if let Some(ref compute_resources) = self.compute_resources {
51            ::serde::ser::SerializeMap::serialize_entry(&mut map, "ComputeResources", compute_resources)?;
52        }
53        if let Some(ref service_role) = self.service_role {
54            ::serde::ser::SerializeMap::serialize_entry(&mut map, "ServiceRole", service_role)?;
55        }
56        if let Some(ref state) = self.state {
57            ::serde::ser::SerializeMap::serialize_entry(&mut map, "State", state)?;
58        }
59        if let Some(ref tags) = self.tags {
60            ::serde::ser::SerializeMap::serialize_entry(&mut map, "Tags", tags)?;
61        }
62        ::serde::ser::SerializeMap::serialize_entry(&mut map, "Type", &self.r#type)?;
63        ::serde::ser::SerializeMap::end(map)
64    }
65}
66
67impl<'de> ::serde::Deserialize<'de> for ComputeEnvironmentProperties {
68    fn deserialize<D: ::serde::Deserializer<'de>>(d: D) -> Result<ComputeEnvironmentProperties, D::Error> {
69        struct Visitor;
70
71        impl<'de> ::serde::de::Visitor<'de> for Visitor {
72            type Value = ComputeEnvironmentProperties;
73
74            fn expecting(&self, f: &mut ::std::fmt::Formatter) -> ::std::fmt::Result {
75                write!(f, "a struct of type ComputeEnvironmentProperties")
76            }
77
78            fn visit_map<A: ::serde::de::MapAccess<'de>>(self, mut map: A) -> Result<Self::Value, A::Error> {
79                let mut compute_environment_name: Option<::Value<String>> = None;
80                let mut compute_resources: Option<::Value<self::compute_environment::ComputeResources>> = None;
81                let mut service_role: Option<::Value<String>> = None;
82                let mut state: Option<::Value<String>> = None;
83                let mut tags: Option<::Value<::json::Value>> = None;
84                let mut r#type: Option<::Value<String>> = None;
85
86                while let Some(__cfn_key) = ::serde::de::MapAccess::next_key::<String>(&mut map)? {
87                    match __cfn_key.as_ref() {
88                        "ComputeEnvironmentName" => {
89                            compute_environment_name = ::serde::de::MapAccess::next_value(&mut map)?;
90                        }
91                        "ComputeResources" => {
92                            compute_resources = ::serde::de::MapAccess::next_value(&mut map)?;
93                        }
94                        "ServiceRole" => {
95                            service_role = ::serde::de::MapAccess::next_value(&mut map)?;
96                        }
97                        "State" => {
98                            state = ::serde::de::MapAccess::next_value(&mut map)?;
99                        }
100                        "Tags" => {
101                            tags = ::serde::de::MapAccess::next_value(&mut map)?;
102                        }
103                        "Type" => {
104                            r#type = ::serde::de::MapAccess::next_value(&mut map)?;
105                        }
106                        _ => {}
107                    }
108                }
109
110                Ok(ComputeEnvironmentProperties {
111                    compute_environment_name: compute_environment_name,
112                    compute_resources: compute_resources,
113                    service_role: service_role,
114                    state: state,
115                    tags: tags,
116                    r#type: r#type.ok_or(::serde::de::Error::missing_field("Type"))?,
117                })
118            }
119        }
120
121        d.deserialize_map(Visitor)
122    }
123}
124
125impl ::Resource for ComputeEnvironment {
126    type Properties = ComputeEnvironmentProperties;
127    const TYPE: &'static str = "AWS::Batch::ComputeEnvironment";
128    fn properties(&self) -> &ComputeEnvironmentProperties {
129        &self.properties
130    }
131    fn properties_mut(&mut self) -> &mut ComputeEnvironmentProperties {
132        &mut self.properties
133    }
134}
135
136impl ::private::Sealed for ComputeEnvironment {}
137
138impl From<ComputeEnvironmentProperties> for ComputeEnvironment {
139    fn from(properties: ComputeEnvironmentProperties) -> ComputeEnvironment {
140        ComputeEnvironment { properties }
141    }
142}
143
144/// The [`AWS::Batch::JobDefinition`](http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-batch-jobdefinition.html) resource type.
145#[derive(Debug, Default)]
146pub struct JobDefinition {
147    properties: JobDefinitionProperties
148}
149
150/// Properties for the `JobDefinition` resource.
151#[derive(Debug, Default)]
152pub struct JobDefinitionProperties {
153    /// Property [`ContainerProperties`](http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-batch-jobdefinition.html#cfn-batch-jobdefinition-containerproperties).
154    ///
155    /// Update type: _Mutable_.
156    /// AWS CloudFormation doesn't replace the resource when you change this property.
157    pub container_properties: Option<::Value<self::job_definition::ContainerProperties>>,
158    /// Property [`JobDefinitionName`](http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-batch-jobdefinition.html#cfn-batch-jobdefinition-jobdefinitionname).
159    ///
160    /// Update type: _Immutable_.
161    /// AWS CloudFormation replaces the resource when you change this property.
162    pub job_definition_name: Option<::Value<String>>,
163    /// Property [`NodeProperties`](http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-batch-jobdefinition.html#cfn-batch-jobdefinition-nodeproperties).
164    ///
165    /// Update type: _Mutable_.
166    /// AWS CloudFormation doesn't replace the resource when you change this property.
167    pub node_properties: Option<::Value<self::job_definition::NodeProperties>>,
168    /// Property [`Parameters`](http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-batch-jobdefinition.html#cfn-batch-jobdefinition-parameters).
169    ///
170    /// Update type: _Mutable_.
171    /// AWS CloudFormation doesn't replace the resource when you change this property.
172    pub parameters: Option<::Value<::json::Value>>,
173    /// Property [`PlatformCapabilities`](http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-batch-jobdefinition.html#cfn-batch-jobdefinition-platformcapabilities).
174    ///
175    /// Update type: _Mutable_.
176    /// AWS CloudFormation doesn't replace the resource when you change this property.
177    pub platform_capabilities: Option<::ValueList<String>>,
178    /// Property [`PropagateTags`](http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-batch-jobdefinition.html#cfn-batch-jobdefinition-propagatetags).
179    ///
180    /// Update type: _Mutable_.
181    /// AWS CloudFormation doesn't replace the resource when you change this property.
182    pub propagate_tags: Option<::Value<bool>>,
183    /// Property [`RetryStrategy`](http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-batch-jobdefinition.html#cfn-batch-jobdefinition-retrystrategy).
184    ///
185    /// Update type: _Mutable_.
186    /// AWS CloudFormation doesn't replace the resource when you change this property.
187    pub retry_strategy: Option<::Value<self::job_definition::RetryStrategy>>,
188    /// Property [`Tags`](http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-batch-jobdefinition.html#cfn-batch-jobdefinition-tags).
189    ///
190    /// Update type: _Immutable_.
191    /// AWS CloudFormation replaces the resource when you change this property.
192    pub tags: Option<::Value<::json::Value>>,
193    /// Property [`Timeout`](http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-batch-jobdefinition.html#cfn-batch-jobdefinition-timeout).
194    ///
195    /// Update type: _Mutable_.
196    /// AWS CloudFormation doesn't replace the resource when you change this property.
197    pub timeout: Option<::Value<self::job_definition::Timeout>>,
198    /// Property [`Type`](http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-batch-jobdefinition.html#cfn-batch-jobdefinition-type).
199    ///
200    /// Update type: _Mutable_.
201    /// AWS CloudFormation doesn't replace the resource when you change this property.
202    pub r#type: ::Value<String>,
203}
204
205impl ::serde::Serialize for JobDefinitionProperties {
206    fn serialize<S: ::serde::Serializer>(&self, s: S) -> Result<S::Ok, S::Error> {
207        let mut map = ::serde::Serializer::serialize_map(s, None)?;
208        if let Some(ref container_properties) = self.container_properties {
209            ::serde::ser::SerializeMap::serialize_entry(&mut map, "ContainerProperties", container_properties)?;
210        }
211        if let Some(ref job_definition_name) = self.job_definition_name {
212            ::serde::ser::SerializeMap::serialize_entry(&mut map, "JobDefinitionName", job_definition_name)?;
213        }
214        if let Some(ref node_properties) = self.node_properties {
215            ::serde::ser::SerializeMap::serialize_entry(&mut map, "NodeProperties", node_properties)?;
216        }
217        if let Some(ref parameters) = self.parameters {
218            ::serde::ser::SerializeMap::serialize_entry(&mut map, "Parameters", parameters)?;
219        }
220        if let Some(ref platform_capabilities) = self.platform_capabilities {
221            ::serde::ser::SerializeMap::serialize_entry(&mut map, "PlatformCapabilities", platform_capabilities)?;
222        }
223        if let Some(ref propagate_tags) = self.propagate_tags {
224            ::serde::ser::SerializeMap::serialize_entry(&mut map, "PropagateTags", propagate_tags)?;
225        }
226        if let Some(ref retry_strategy) = self.retry_strategy {
227            ::serde::ser::SerializeMap::serialize_entry(&mut map, "RetryStrategy", retry_strategy)?;
228        }
229        if let Some(ref tags) = self.tags {
230            ::serde::ser::SerializeMap::serialize_entry(&mut map, "Tags", tags)?;
231        }
232        if let Some(ref timeout) = self.timeout {
233            ::serde::ser::SerializeMap::serialize_entry(&mut map, "Timeout", timeout)?;
234        }
235        ::serde::ser::SerializeMap::serialize_entry(&mut map, "Type", &self.r#type)?;
236        ::serde::ser::SerializeMap::end(map)
237    }
238}
239
240impl<'de> ::serde::Deserialize<'de> for JobDefinitionProperties {
241    fn deserialize<D: ::serde::Deserializer<'de>>(d: D) -> Result<JobDefinitionProperties, D::Error> {
242        struct Visitor;
243
244        impl<'de> ::serde::de::Visitor<'de> for Visitor {
245            type Value = JobDefinitionProperties;
246
247            fn expecting(&self, f: &mut ::std::fmt::Formatter) -> ::std::fmt::Result {
248                write!(f, "a struct of type JobDefinitionProperties")
249            }
250
251            fn visit_map<A: ::serde::de::MapAccess<'de>>(self, mut map: A) -> Result<Self::Value, A::Error> {
252                let mut container_properties: Option<::Value<self::job_definition::ContainerProperties>> = None;
253                let mut job_definition_name: Option<::Value<String>> = None;
254                let mut node_properties: Option<::Value<self::job_definition::NodeProperties>> = None;
255                let mut parameters: Option<::Value<::json::Value>> = None;
256                let mut platform_capabilities: Option<::ValueList<String>> = None;
257                let mut propagate_tags: Option<::Value<bool>> = None;
258                let mut retry_strategy: Option<::Value<self::job_definition::RetryStrategy>> = None;
259                let mut tags: Option<::Value<::json::Value>> = None;
260                let mut timeout: Option<::Value<self::job_definition::Timeout>> = None;
261                let mut r#type: Option<::Value<String>> = None;
262
263                while let Some(__cfn_key) = ::serde::de::MapAccess::next_key::<String>(&mut map)? {
264                    match __cfn_key.as_ref() {
265                        "ContainerProperties" => {
266                            container_properties = ::serde::de::MapAccess::next_value(&mut map)?;
267                        }
268                        "JobDefinitionName" => {
269                            job_definition_name = ::serde::de::MapAccess::next_value(&mut map)?;
270                        }
271                        "NodeProperties" => {
272                            node_properties = ::serde::de::MapAccess::next_value(&mut map)?;
273                        }
274                        "Parameters" => {
275                            parameters = ::serde::de::MapAccess::next_value(&mut map)?;
276                        }
277                        "PlatformCapabilities" => {
278                            platform_capabilities = ::serde::de::MapAccess::next_value(&mut map)?;
279                        }
280                        "PropagateTags" => {
281                            propagate_tags = ::serde::de::MapAccess::next_value(&mut map)?;
282                        }
283                        "RetryStrategy" => {
284                            retry_strategy = ::serde::de::MapAccess::next_value(&mut map)?;
285                        }
286                        "Tags" => {
287                            tags = ::serde::de::MapAccess::next_value(&mut map)?;
288                        }
289                        "Timeout" => {
290                            timeout = ::serde::de::MapAccess::next_value(&mut map)?;
291                        }
292                        "Type" => {
293                            r#type = ::serde::de::MapAccess::next_value(&mut map)?;
294                        }
295                        _ => {}
296                    }
297                }
298
299                Ok(JobDefinitionProperties {
300                    container_properties: container_properties,
301                    job_definition_name: job_definition_name,
302                    node_properties: node_properties,
303                    parameters: parameters,
304                    platform_capabilities: platform_capabilities,
305                    propagate_tags: propagate_tags,
306                    retry_strategy: retry_strategy,
307                    tags: tags,
308                    timeout: timeout,
309                    r#type: r#type.ok_or(::serde::de::Error::missing_field("Type"))?,
310                })
311            }
312        }
313
314        d.deserialize_map(Visitor)
315    }
316}
317
318impl ::Resource for JobDefinition {
319    type Properties = JobDefinitionProperties;
320    const TYPE: &'static str = "AWS::Batch::JobDefinition";
321    fn properties(&self) -> &JobDefinitionProperties {
322        &self.properties
323    }
324    fn properties_mut(&mut self) -> &mut JobDefinitionProperties {
325        &mut self.properties
326    }
327}
328
329impl ::private::Sealed for JobDefinition {}
330
331impl From<JobDefinitionProperties> for JobDefinition {
332    fn from(properties: JobDefinitionProperties) -> JobDefinition {
333        JobDefinition { properties }
334    }
335}
336
337/// The [`AWS::Batch::JobQueue`](http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-batch-jobqueue.html) resource type.
338#[derive(Debug, Default)]
339pub struct JobQueue {
340    properties: JobQueueProperties
341}
342
343/// Properties for the `JobQueue` resource.
344#[derive(Debug, Default)]
345pub struct JobQueueProperties {
346    /// Property [`ComputeEnvironmentOrder`](http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-batch-jobqueue.html#cfn-batch-jobqueue-computeenvironmentorder).
347    ///
348    /// Update type: _Mutable_.
349    /// AWS CloudFormation doesn't replace the resource when you change this property.
350    pub compute_environment_order: ::ValueList<self::job_queue::ComputeEnvironmentOrder>,
351    /// Property [`JobQueueName`](http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-batch-jobqueue.html#cfn-batch-jobqueue-jobqueuename).
352    ///
353    /// Update type: _Immutable_.
354    /// AWS CloudFormation replaces the resource when you change this property.
355    pub job_queue_name: Option<::Value<String>>,
356    /// Property [`Priority`](http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-batch-jobqueue.html#cfn-batch-jobqueue-priority).
357    ///
358    /// Update type: _Mutable_.
359    /// AWS CloudFormation doesn't replace the resource when you change this property.
360    pub priority: ::Value<u32>,
361    /// Property [`State`](http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-batch-jobqueue.html#cfn-batch-jobqueue-state).
362    ///
363    /// Update type: _Mutable_.
364    /// AWS CloudFormation doesn't replace the resource when you change this property.
365    pub state: Option<::Value<String>>,
366    /// Property [`Tags`](http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-batch-jobqueue.html#cfn-batch-jobqueue-tags).
367    ///
368    /// Update type: _Immutable_.
369    /// AWS CloudFormation replaces the resource when you change this property.
370    pub tags: Option<::Value<::json::Value>>,
371}
372
373impl ::serde::Serialize for JobQueueProperties {
374    fn serialize<S: ::serde::Serializer>(&self, s: S) -> Result<S::Ok, S::Error> {
375        let mut map = ::serde::Serializer::serialize_map(s, None)?;
376        ::serde::ser::SerializeMap::serialize_entry(&mut map, "ComputeEnvironmentOrder", &self.compute_environment_order)?;
377        if let Some(ref job_queue_name) = self.job_queue_name {
378            ::serde::ser::SerializeMap::serialize_entry(&mut map, "JobQueueName", job_queue_name)?;
379        }
380        ::serde::ser::SerializeMap::serialize_entry(&mut map, "Priority", &self.priority)?;
381        if let Some(ref state) = self.state {
382            ::serde::ser::SerializeMap::serialize_entry(&mut map, "State", state)?;
383        }
384        if let Some(ref tags) = self.tags {
385            ::serde::ser::SerializeMap::serialize_entry(&mut map, "Tags", tags)?;
386        }
387        ::serde::ser::SerializeMap::end(map)
388    }
389}
390
391impl<'de> ::serde::Deserialize<'de> for JobQueueProperties {
392    fn deserialize<D: ::serde::Deserializer<'de>>(d: D) -> Result<JobQueueProperties, D::Error> {
393        struct Visitor;
394
395        impl<'de> ::serde::de::Visitor<'de> for Visitor {
396            type Value = JobQueueProperties;
397
398            fn expecting(&self, f: &mut ::std::fmt::Formatter) -> ::std::fmt::Result {
399                write!(f, "a struct of type JobQueueProperties")
400            }
401
402            fn visit_map<A: ::serde::de::MapAccess<'de>>(self, mut map: A) -> Result<Self::Value, A::Error> {
403                let mut compute_environment_order: Option<::ValueList<self::job_queue::ComputeEnvironmentOrder>> = None;
404                let mut job_queue_name: Option<::Value<String>> = None;
405                let mut priority: Option<::Value<u32>> = None;
406                let mut state: Option<::Value<String>> = None;
407                let mut tags: Option<::Value<::json::Value>> = None;
408
409                while let Some(__cfn_key) = ::serde::de::MapAccess::next_key::<String>(&mut map)? {
410                    match __cfn_key.as_ref() {
411                        "ComputeEnvironmentOrder" => {
412                            compute_environment_order = ::serde::de::MapAccess::next_value(&mut map)?;
413                        }
414                        "JobQueueName" => {
415                            job_queue_name = ::serde::de::MapAccess::next_value(&mut map)?;
416                        }
417                        "Priority" => {
418                            priority = ::serde::de::MapAccess::next_value(&mut map)?;
419                        }
420                        "State" => {
421                            state = ::serde::de::MapAccess::next_value(&mut map)?;
422                        }
423                        "Tags" => {
424                            tags = ::serde::de::MapAccess::next_value(&mut map)?;
425                        }
426                        _ => {}
427                    }
428                }
429
430                Ok(JobQueueProperties {
431                    compute_environment_order: compute_environment_order.ok_or(::serde::de::Error::missing_field("ComputeEnvironmentOrder"))?,
432                    job_queue_name: job_queue_name,
433                    priority: priority.ok_or(::serde::de::Error::missing_field("Priority"))?,
434                    state: state,
435                    tags: tags,
436                })
437            }
438        }
439
440        d.deserialize_map(Visitor)
441    }
442}
443
444impl ::Resource for JobQueue {
445    type Properties = JobQueueProperties;
446    const TYPE: &'static str = "AWS::Batch::JobQueue";
447    fn properties(&self) -> &JobQueueProperties {
448        &self.properties
449    }
450    fn properties_mut(&mut self) -> &mut JobQueueProperties {
451        &mut self.properties
452    }
453}
454
455impl ::private::Sealed for JobQueue {}
456
457impl From<JobQueueProperties> for JobQueue {
458    fn from(properties: JobQueueProperties) -> JobQueue {
459        JobQueue { properties }
460    }
461}
462
463pub mod compute_environment {
464    //! Property types for the `ComputeEnvironment` resource.
465
466    /// The [`AWS::Batch::ComputeEnvironment.ComputeResources`](http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-batch-computeenvironment-computeresources.html) property type.
467    #[derive(Debug, Default)]
468    pub struct ComputeResources {
469        /// Property [`AllocationStrategy`](http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-batch-computeenvironment-computeresources.html#cfn-batch-computeenvironment-computeresources-allocationstrategy).
470        ///
471        /// Update type: _Immutable_.
472        /// AWS CloudFormation replaces the resource when you change this property.
473        pub allocation_strategy: Option<::Value<String>>,
474        /// Property [`BidPercentage`](http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-batch-computeenvironment-computeresources.html#cfn-batch-computeenvironment-computeresources-bidpercentage).
475        ///
476        /// Update type: _Immutable_.
477        /// AWS CloudFormation replaces the resource when you change this property.
478        pub bid_percentage: Option<::Value<u32>>,
479        /// Property [`DesiredvCpus`](http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-batch-computeenvironment-computeresources.html#cfn-batch-computeenvironment-computeresources-desiredvcpus).
480        ///
481        /// Update type: _Mutable_.
482        /// AWS CloudFormation doesn't replace the resource when you change this property.
483        pub desiredv_cpus: Option<::Value<u32>>,
484        /// Property [`Ec2Configuration`](http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-batch-computeenvironment-computeresources.html#cfn-batch-computeenvironment-computeresources-ec2configuration).
485        ///
486        /// Update type: _Immutable_.
487        /// AWS CloudFormation replaces the resource when you change this property.
488        pub ec2_configuration: Option<::ValueList<Ec2ConfigurationObject>>,
489        /// Property [`Ec2KeyPair`](http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-batch-computeenvironment-computeresources.html#cfn-batch-computeenvironment-computeresources-ec2keypair).
490        ///
491        /// Update type: _Immutable_.
492        /// AWS CloudFormation replaces the resource when you change this property.
493        pub ec2_key_pair: Option<::Value<String>>,
494        /// Property [`ImageId`](http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-batch-computeenvironment-computeresources.html#cfn-batch-computeenvironment-computeresources-imageid).
495        ///
496        /// Update type: _Immutable_.
497        /// AWS CloudFormation replaces the resource when you change this property.
498        pub image_id: Option<::Value<String>>,
499        /// Property [`InstanceRole`](http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-batch-computeenvironment-computeresources.html#cfn-batch-computeenvironment-computeresources-instancerole).
500        ///
501        /// Update type: _Immutable_.
502        /// AWS CloudFormation replaces the resource when you change this property.
503        pub instance_role: Option<::Value<String>>,
504        /// Property [`InstanceTypes`](http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-batch-computeenvironment-computeresources.html#cfn-batch-computeenvironment-computeresources-instancetypes).
505        ///
506        /// Update type: _Immutable_.
507        /// AWS CloudFormation replaces the resource when you change this property.
508        pub instance_types: Option<::ValueList<String>>,
509        /// Property [`LaunchTemplate`](http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-batch-computeenvironment-computeresources.html#cfn-batch-computeenvironment-computeresources-launchtemplate).
510        ///
511        /// Update type: _Immutable_.
512        /// AWS CloudFormation replaces the resource when you change this property.
513        pub launch_template: Option<::Value<LaunchTemplateSpecification>>,
514        /// Property [`MaxvCpus`](http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-batch-computeenvironment-computeresources.html#cfn-batch-computeenvironment-computeresources-maxvcpus).
515        ///
516        /// Update type: _Mutable_.
517        /// AWS CloudFormation doesn't replace the resource when you change this property.
518        pub maxv_cpus: ::Value<u32>,
519        /// Property [`MinvCpus`](http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-batch-computeenvironment-computeresources.html#cfn-batch-computeenvironment-computeresources-minvcpus).
520        ///
521        /// Update type: _Mutable_.
522        /// AWS CloudFormation doesn't replace the resource when you change this property.
523        pub minv_cpus: Option<::Value<u32>>,
524        /// Property [`PlacementGroup`](http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-batch-computeenvironment-computeresources.html#cfn-batch-computeenvironment-computeresources-placementgroup).
525        ///
526        /// Update type: _Immutable_.
527        /// AWS CloudFormation replaces the resource when you change this property.
528        pub placement_group: Option<::Value<String>>,
529        /// Property [`SecurityGroupIds`](http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-batch-computeenvironment-computeresources.html#cfn-batch-computeenvironment-computeresources-securitygroupids).
530        ///
531        /// Update type: _Mutable_.
532        /// AWS CloudFormation doesn't replace the resource when you change this property.
533        pub security_group_ids: Option<::ValueList<String>>,
534        /// Property [`SpotIamFleetRole`](http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-batch-computeenvironment-computeresources.html#cfn-batch-computeenvironment-computeresources-spotiamfleetrole).
535        ///
536        /// Update type: _Immutable_.
537        /// AWS CloudFormation replaces the resource when you change this property.
538        pub spot_iam_fleet_role: Option<::Value<String>>,
539        /// Property [`Subnets`](http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-batch-computeenvironment-computeresources.html#cfn-batch-computeenvironment-computeresources-subnets).
540        ///
541        /// Update type: _Mutable_.
542        /// AWS CloudFormation doesn't replace the resource when you change this property.
543        pub subnets: ::ValueList<String>,
544        /// Property [`Tags`](http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-batch-computeenvironment-computeresources.html#cfn-batch-computeenvironment-computeresources-tags).
545        ///
546        /// Update type: _Immutable_.
547        /// AWS CloudFormation replaces the resource when you change this property.
548        pub tags: Option<::Value<::json::Value>>,
549        /// Property [`Type`](http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-batch-computeenvironment-computeresources.html#cfn-batch-computeenvironment-computeresources-type).
550        ///
551        /// Update type: _Immutable_.
552        /// AWS CloudFormation replaces the resource when you change this property.
553        pub r#type: ::Value<String>,
554    }
555
556    impl ::codec::SerializeValue for ComputeResources {
557        fn serialize<S: ::serde::Serializer>(&self, s: S) -> Result<S::Ok, S::Error> {
558            let mut map = ::serde::Serializer::serialize_map(s, None)?;
559            if let Some(ref allocation_strategy) = self.allocation_strategy {
560                ::serde::ser::SerializeMap::serialize_entry(&mut map, "AllocationStrategy", allocation_strategy)?;
561            }
562            if let Some(ref bid_percentage) = self.bid_percentage {
563                ::serde::ser::SerializeMap::serialize_entry(&mut map, "BidPercentage", bid_percentage)?;
564            }
565            if let Some(ref desiredv_cpus) = self.desiredv_cpus {
566                ::serde::ser::SerializeMap::serialize_entry(&mut map, "DesiredvCpus", desiredv_cpus)?;
567            }
568            if let Some(ref ec2_configuration) = self.ec2_configuration {
569                ::serde::ser::SerializeMap::serialize_entry(&mut map, "Ec2Configuration", ec2_configuration)?;
570            }
571            if let Some(ref ec2_key_pair) = self.ec2_key_pair {
572                ::serde::ser::SerializeMap::serialize_entry(&mut map, "Ec2KeyPair", ec2_key_pair)?;
573            }
574            if let Some(ref image_id) = self.image_id {
575                ::serde::ser::SerializeMap::serialize_entry(&mut map, "ImageId", image_id)?;
576            }
577            if let Some(ref instance_role) = self.instance_role {
578                ::serde::ser::SerializeMap::serialize_entry(&mut map, "InstanceRole", instance_role)?;
579            }
580            if let Some(ref instance_types) = self.instance_types {
581                ::serde::ser::SerializeMap::serialize_entry(&mut map, "InstanceTypes", instance_types)?;
582            }
583            if let Some(ref launch_template) = self.launch_template {
584                ::serde::ser::SerializeMap::serialize_entry(&mut map, "LaunchTemplate", launch_template)?;
585            }
586            ::serde::ser::SerializeMap::serialize_entry(&mut map, "MaxvCpus", &self.maxv_cpus)?;
587            if let Some(ref minv_cpus) = self.minv_cpus {
588                ::serde::ser::SerializeMap::serialize_entry(&mut map, "MinvCpus", minv_cpus)?;
589            }
590            if let Some(ref placement_group) = self.placement_group {
591                ::serde::ser::SerializeMap::serialize_entry(&mut map, "PlacementGroup", placement_group)?;
592            }
593            if let Some(ref security_group_ids) = self.security_group_ids {
594                ::serde::ser::SerializeMap::serialize_entry(&mut map, "SecurityGroupIds", security_group_ids)?;
595            }
596            if let Some(ref spot_iam_fleet_role) = self.spot_iam_fleet_role {
597                ::serde::ser::SerializeMap::serialize_entry(&mut map, "SpotIamFleetRole", spot_iam_fleet_role)?;
598            }
599            ::serde::ser::SerializeMap::serialize_entry(&mut map, "Subnets", &self.subnets)?;
600            if let Some(ref tags) = self.tags {
601                ::serde::ser::SerializeMap::serialize_entry(&mut map, "Tags", tags)?;
602            }
603            ::serde::ser::SerializeMap::serialize_entry(&mut map, "Type", &self.r#type)?;
604            ::serde::ser::SerializeMap::end(map)
605        }
606    }
607
608    impl ::codec::DeserializeValue for ComputeResources {
609        fn deserialize<'de, D: ::serde::Deserializer<'de>>(d: D) -> Result<ComputeResources, D::Error> {
610            struct Visitor;
611
612            impl<'de> ::serde::de::Visitor<'de> for Visitor {
613                type Value = ComputeResources;
614
615                fn expecting(&self, f: &mut ::std::fmt::Formatter) -> ::std::fmt::Result {
616                    write!(f, "a struct of type ComputeResources")
617                }
618
619                fn visit_map<A: ::serde::de::MapAccess<'de>>(self, mut map: A) -> Result<Self::Value, A::Error> {
620                    let mut allocation_strategy: Option<::Value<String>> = None;
621                    let mut bid_percentage: Option<::Value<u32>> = None;
622                    let mut desiredv_cpus: Option<::Value<u32>> = None;
623                    let mut ec2_configuration: Option<::ValueList<Ec2ConfigurationObject>> = None;
624                    let mut ec2_key_pair: Option<::Value<String>> = None;
625                    let mut image_id: Option<::Value<String>> = None;
626                    let mut instance_role: Option<::Value<String>> = None;
627                    let mut instance_types: Option<::ValueList<String>> = None;
628                    let mut launch_template: Option<::Value<LaunchTemplateSpecification>> = None;
629                    let mut maxv_cpus: Option<::Value<u32>> = None;
630                    let mut minv_cpus: Option<::Value<u32>> = None;
631                    let mut placement_group: Option<::Value<String>> = None;
632                    let mut security_group_ids: Option<::ValueList<String>> = None;
633                    let mut spot_iam_fleet_role: Option<::Value<String>> = None;
634                    let mut subnets: Option<::ValueList<String>> = None;
635                    let mut tags: Option<::Value<::json::Value>> = None;
636                    let mut r#type: Option<::Value<String>> = None;
637
638                    while let Some(__cfn_key) = ::serde::de::MapAccess::next_key::<String>(&mut map)? {
639                        match __cfn_key.as_ref() {
640                            "AllocationStrategy" => {
641                                allocation_strategy = ::serde::de::MapAccess::next_value(&mut map)?;
642                            }
643                            "BidPercentage" => {
644                                bid_percentage = ::serde::de::MapAccess::next_value(&mut map)?;
645                            }
646                            "DesiredvCpus" => {
647                                desiredv_cpus = ::serde::de::MapAccess::next_value(&mut map)?;
648                            }
649                            "Ec2Configuration" => {
650                                ec2_configuration = ::serde::de::MapAccess::next_value(&mut map)?;
651                            }
652                            "Ec2KeyPair" => {
653                                ec2_key_pair = ::serde::de::MapAccess::next_value(&mut map)?;
654                            }
655                            "ImageId" => {
656                                image_id = ::serde::de::MapAccess::next_value(&mut map)?;
657                            }
658                            "InstanceRole" => {
659                                instance_role = ::serde::de::MapAccess::next_value(&mut map)?;
660                            }
661                            "InstanceTypes" => {
662                                instance_types = ::serde::de::MapAccess::next_value(&mut map)?;
663                            }
664                            "LaunchTemplate" => {
665                                launch_template = ::serde::de::MapAccess::next_value(&mut map)?;
666                            }
667                            "MaxvCpus" => {
668                                maxv_cpus = ::serde::de::MapAccess::next_value(&mut map)?;
669                            }
670                            "MinvCpus" => {
671                                minv_cpus = ::serde::de::MapAccess::next_value(&mut map)?;
672                            }
673                            "PlacementGroup" => {
674                                placement_group = ::serde::de::MapAccess::next_value(&mut map)?;
675                            }
676                            "SecurityGroupIds" => {
677                                security_group_ids = ::serde::de::MapAccess::next_value(&mut map)?;
678                            }
679                            "SpotIamFleetRole" => {
680                                spot_iam_fleet_role = ::serde::de::MapAccess::next_value(&mut map)?;
681                            }
682                            "Subnets" => {
683                                subnets = ::serde::de::MapAccess::next_value(&mut map)?;
684                            }
685                            "Tags" => {
686                                tags = ::serde::de::MapAccess::next_value(&mut map)?;
687                            }
688                            "Type" => {
689                                r#type = ::serde::de::MapAccess::next_value(&mut map)?;
690                            }
691                            _ => {}
692                        }
693                    }
694
695                    Ok(ComputeResources {
696                        allocation_strategy: allocation_strategy,
697                        bid_percentage: bid_percentage,
698                        desiredv_cpus: desiredv_cpus,
699                        ec2_configuration: ec2_configuration,
700                        ec2_key_pair: ec2_key_pair,
701                        image_id: image_id,
702                        instance_role: instance_role,
703                        instance_types: instance_types,
704                        launch_template: launch_template,
705                        maxv_cpus: maxv_cpus.ok_or(::serde::de::Error::missing_field("MaxvCpus"))?,
706                        minv_cpus: minv_cpus,
707                        placement_group: placement_group,
708                        security_group_ids: security_group_ids,
709                        spot_iam_fleet_role: spot_iam_fleet_role,
710                        subnets: subnets.ok_or(::serde::de::Error::missing_field("Subnets"))?,
711                        tags: tags,
712                        r#type: r#type.ok_or(::serde::de::Error::missing_field("Type"))?,
713                    })
714                }
715            }
716
717            d.deserialize_map(Visitor)
718        }
719    }
720
721    /// The [`AWS::Batch::ComputeEnvironment.Ec2ConfigurationObject`](http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-batch-computeenvironment-ec2configurationobject.html) property type.
722    #[derive(Debug, Default)]
723    pub struct Ec2ConfigurationObject {
724        /// Property [`ImageIdOverride`](http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-batch-computeenvironment-ec2configurationobject.html#cfn-batch-computeenvironment-ec2configurationobject-imageidoverride).
725        ///
726        /// Update type: _Immutable_.
727        /// AWS CloudFormation replaces the resource when you change this property.
728        pub image_id_override: Option<::Value<String>>,
729        /// Property [`ImageType`](http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-batch-computeenvironment-ec2configurationobject.html#cfn-batch-computeenvironment-ec2configurationobject-imagetype).
730        ///
731        /// Update type: _Immutable_.
732        /// AWS CloudFormation replaces the resource when you change this property.
733        pub image_type: ::Value<String>,
734    }
735
736    impl ::codec::SerializeValue for Ec2ConfigurationObject {
737        fn serialize<S: ::serde::Serializer>(&self, s: S) -> Result<S::Ok, S::Error> {
738            let mut map = ::serde::Serializer::serialize_map(s, None)?;
739            if let Some(ref image_id_override) = self.image_id_override {
740                ::serde::ser::SerializeMap::serialize_entry(&mut map, "ImageIdOverride", image_id_override)?;
741            }
742            ::serde::ser::SerializeMap::serialize_entry(&mut map, "ImageType", &self.image_type)?;
743            ::serde::ser::SerializeMap::end(map)
744        }
745    }
746
747    impl ::codec::DeserializeValue for Ec2ConfigurationObject {
748        fn deserialize<'de, D: ::serde::Deserializer<'de>>(d: D) -> Result<Ec2ConfigurationObject, D::Error> {
749            struct Visitor;
750
751            impl<'de> ::serde::de::Visitor<'de> for Visitor {
752                type Value = Ec2ConfigurationObject;
753
754                fn expecting(&self, f: &mut ::std::fmt::Formatter) -> ::std::fmt::Result {
755                    write!(f, "a struct of type Ec2ConfigurationObject")
756                }
757
758                fn visit_map<A: ::serde::de::MapAccess<'de>>(self, mut map: A) -> Result<Self::Value, A::Error> {
759                    let mut image_id_override: Option<::Value<String>> = None;
760                    let mut image_type: Option<::Value<String>> = None;
761
762                    while let Some(__cfn_key) = ::serde::de::MapAccess::next_key::<String>(&mut map)? {
763                        match __cfn_key.as_ref() {
764                            "ImageIdOverride" => {
765                                image_id_override = ::serde::de::MapAccess::next_value(&mut map)?;
766                            }
767                            "ImageType" => {
768                                image_type = ::serde::de::MapAccess::next_value(&mut map)?;
769                            }
770                            _ => {}
771                        }
772                    }
773
774                    Ok(Ec2ConfigurationObject {
775                        image_id_override: image_id_override,
776                        image_type: image_type.ok_or(::serde::de::Error::missing_field("ImageType"))?,
777                    })
778                }
779            }
780
781            d.deserialize_map(Visitor)
782        }
783    }
784
785    /// The [`AWS::Batch::ComputeEnvironment.LaunchTemplateSpecification`](http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-batch-computeenvironment-launchtemplatespecification.html) property type.
786    #[derive(Debug, Default)]
787    pub struct LaunchTemplateSpecification {
788        /// Property [`LaunchTemplateId`](http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-batch-computeenvironment-launchtemplatespecification.html#cfn-batch-computeenvironment-launchtemplatespecification-launchtemplateid).
789        ///
790        /// Update type: _Immutable_.
791        /// AWS CloudFormation replaces the resource when you change this property.
792        pub launch_template_id: Option<::Value<String>>,
793        /// Property [`LaunchTemplateName`](http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-batch-computeenvironment-launchtemplatespecification.html#cfn-batch-computeenvironment-launchtemplatespecification-launchtemplatename).
794        ///
795        /// Update type: _Immutable_.
796        /// AWS CloudFormation replaces the resource when you change this property.
797        pub launch_template_name: Option<::Value<String>>,
798        /// Property [`Version`](http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-batch-computeenvironment-launchtemplatespecification.html#cfn-batch-computeenvironment-launchtemplatespecification-version).
799        ///
800        /// Update type: _Immutable_.
801        /// AWS CloudFormation replaces the resource when you change this property.
802        pub version: Option<::Value<String>>,
803    }
804
805    impl ::codec::SerializeValue for LaunchTemplateSpecification {
806        fn serialize<S: ::serde::Serializer>(&self, s: S) -> Result<S::Ok, S::Error> {
807            let mut map = ::serde::Serializer::serialize_map(s, None)?;
808            if let Some(ref launch_template_id) = self.launch_template_id {
809                ::serde::ser::SerializeMap::serialize_entry(&mut map, "LaunchTemplateId", launch_template_id)?;
810            }
811            if let Some(ref launch_template_name) = self.launch_template_name {
812                ::serde::ser::SerializeMap::serialize_entry(&mut map, "LaunchTemplateName", launch_template_name)?;
813            }
814            if let Some(ref version) = self.version {
815                ::serde::ser::SerializeMap::serialize_entry(&mut map, "Version", version)?;
816            }
817            ::serde::ser::SerializeMap::end(map)
818        }
819    }
820
821    impl ::codec::DeserializeValue for LaunchTemplateSpecification {
822        fn deserialize<'de, D: ::serde::Deserializer<'de>>(d: D) -> Result<LaunchTemplateSpecification, D::Error> {
823            struct Visitor;
824
825            impl<'de> ::serde::de::Visitor<'de> for Visitor {
826                type Value = LaunchTemplateSpecification;
827
828                fn expecting(&self, f: &mut ::std::fmt::Formatter) -> ::std::fmt::Result {
829                    write!(f, "a struct of type LaunchTemplateSpecification")
830                }
831
832                fn visit_map<A: ::serde::de::MapAccess<'de>>(self, mut map: A) -> Result<Self::Value, A::Error> {
833                    let mut launch_template_id: Option<::Value<String>> = None;
834                    let mut launch_template_name: Option<::Value<String>> = None;
835                    let mut version: Option<::Value<String>> = None;
836
837                    while let Some(__cfn_key) = ::serde::de::MapAccess::next_key::<String>(&mut map)? {
838                        match __cfn_key.as_ref() {
839                            "LaunchTemplateId" => {
840                                launch_template_id = ::serde::de::MapAccess::next_value(&mut map)?;
841                            }
842                            "LaunchTemplateName" => {
843                                launch_template_name = ::serde::de::MapAccess::next_value(&mut map)?;
844                            }
845                            "Version" => {
846                                version = ::serde::de::MapAccess::next_value(&mut map)?;
847                            }
848                            _ => {}
849                        }
850                    }
851
852                    Ok(LaunchTemplateSpecification {
853                        launch_template_id: launch_template_id,
854                        launch_template_name: launch_template_name,
855                        version: version,
856                    })
857                }
858            }
859
860            d.deserialize_map(Visitor)
861        }
862    }
863}
864
865pub mod job_definition {
866    //! Property types for the `JobDefinition` resource.
867
868    /// The [`AWS::Batch::JobDefinition.AuthorizationConfig`](http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-batch-jobdefinition-authorizationconfig.html) property type.
869    #[derive(Debug, Default)]
870    pub struct AuthorizationConfig {
871        /// Property [`AccessPointId`](http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-batch-jobdefinition-authorizationconfig.html#cfn-batch-jobdefinition-authorizationconfig-accesspointid).
872        ///
873        /// Update type: _Mutable_.
874        /// AWS CloudFormation doesn't replace the resource when you change this property.
875        pub access_point_id: Option<::Value<String>>,
876        /// Property [`Iam`](http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-batch-jobdefinition-authorizationconfig.html#cfn-batch-jobdefinition-authorizationconfig-iam).
877        ///
878        /// Update type: _Mutable_.
879        /// AWS CloudFormation doesn't replace the resource when you change this property.
880        pub iam: Option<::Value<String>>,
881    }
882
883    impl ::codec::SerializeValue for AuthorizationConfig {
884        fn serialize<S: ::serde::Serializer>(&self, s: S) -> Result<S::Ok, S::Error> {
885            let mut map = ::serde::Serializer::serialize_map(s, None)?;
886            if let Some(ref access_point_id) = self.access_point_id {
887                ::serde::ser::SerializeMap::serialize_entry(&mut map, "AccessPointId", access_point_id)?;
888            }
889            if let Some(ref iam) = self.iam {
890                ::serde::ser::SerializeMap::serialize_entry(&mut map, "Iam", iam)?;
891            }
892            ::serde::ser::SerializeMap::end(map)
893        }
894    }
895
896    impl ::codec::DeserializeValue for AuthorizationConfig {
897        fn deserialize<'de, D: ::serde::Deserializer<'de>>(d: D) -> Result<AuthorizationConfig, D::Error> {
898            struct Visitor;
899
900            impl<'de> ::serde::de::Visitor<'de> for Visitor {
901                type Value = AuthorizationConfig;
902
903                fn expecting(&self, f: &mut ::std::fmt::Formatter) -> ::std::fmt::Result {
904                    write!(f, "a struct of type AuthorizationConfig")
905                }
906
907                fn visit_map<A: ::serde::de::MapAccess<'de>>(self, mut map: A) -> Result<Self::Value, A::Error> {
908                    let mut access_point_id: Option<::Value<String>> = None;
909                    let mut iam: Option<::Value<String>> = None;
910
911                    while let Some(__cfn_key) = ::serde::de::MapAccess::next_key::<String>(&mut map)? {
912                        match __cfn_key.as_ref() {
913                            "AccessPointId" => {
914                                access_point_id = ::serde::de::MapAccess::next_value(&mut map)?;
915                            }
916                            "Iam" => {
917                                iam = ::serde::de::MapAccess::next_value(&mut map)?;
918                            }
919                            _ => {}
920                        }
921                    }
922
923                    Ok(AuthorizationConfig {
924                        access_point_id: access_point_id,
925                        iam: iam,
926                    })
927                }
928            }
929
930            d.deserialize_map(Visitor)
931        }
932    }
933
934    /// The [`AWS::Batch::JobDefinition.ContainerProperties`](http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-batch-jobdefinition-containerproperties.html) property type.
935    #[derive(Debug, Default)]
936    pub struct ContainerProperties {
937        /// Property [`Command`](http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-batch-jobdefinition-containerproperties.html#cfn-batch-jobdefinition-containerproperties-command).
938        ///
939        /// Update type: _Mutable_.
940        /// AWS CloudFormation doesn't replace the resource when you change this property.
941        pub command: Option<::ValueList<String>>,
942        /// Property [`Environment`](http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-batch-jobdefinition-containerproperties.html#cfn-batch-jobdefinition-containerproperties-environment).
943        ///
944        /// Update type: _Mutable_.
945        /// AWS CloudFormation doesn't replace the resource when you change this property.
946        pub environment: Option<::ValueList<Environment>>,
947        /// Property [`ExecutionRoleArn`](http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-batch-jobdefinition-containerproperties.html#cfn-batch-jobdefinition-containerproperties-executionrolearn).
948        ///
949        /// Update type: _Mutable_.
950        /// AWS CloudFormation doesn't replace the resource when you change this property.
951        pub execution_role_arn: Option<::Value<String>>,
952        /// Property [`FargatePlatformConfiguration`](http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-batch-jobdefinition-containerproperties.html#cfn-batch-jobdefinition-containerproperties-fargateplatformconfiguration).
953        ///
954        /// Update type: _Mutable_.
955        /// AWS CloudFormation doesn't replace the resource when you change this property.
956        pub fargate_platform_configuration: Option<::Value<FargatePlatformConfiguration>>,
957        /// Property [`Image`](http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-batch-jobdefinition-containerproperties.html#cfn-batch-jobdefinition-containerproperties-image).
958        ///
959        /// Update type: _Mutable_.
960        /// AWS CloudFormation doesn't replace the resource when you change this property.
961        pub image: ::Value<String>,
962        /// Property [`InstanceType`](http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-batch-jobdefinition-containerproperties.html#cfn-batch-jobdefinition-containerproperties-instancetype).
963        ///
964        /// Update type: _Mutable_.
965        /// AWS CloudFormation doesn't replace the resource when you change this property.
966        pub instance_type: Option<::Value<String>>,
967        /// Property [`JobRoleArn`](http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-batch-jobdefinition-containerproperties.html#cfn-batch-jobdefinition-containerproperties-jobrolearn).
968        ///
969        /// Update type: _Mutable_.
970        /// AWS CloudFormation doesn't replace the resource when you change this property.
971        pub job_role_arn: Option<::Value<String>>,
972        /// Property [`LinuxParameters`](http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-batch-jobdefinition-containerproperties.html#cfn-batch-jobdefinition-containerproperties-linuxparameters).
973        ///
974        /// Update type: _Mutable_.
975        /// AWS CloudFormation doesn't replace the resource when you change this property.
976        pub linux_parameters: Option<::Value<LinuxParameters>>,
977        /// Property [`LogConfiguration`](http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-batch-jobdefinition-containerproperties.html#cfn-batch-jobdefinition-containerproperties-logconfiguration).
978        ///
979        /// Update type: _Mutable_.
980        /// AWS CloudFormation doesn't replace the resource when you change this property.
981        pub log_configuration: Option<::Value<LogConfiguration>>,
982        /// Property [`Memory`](http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-batch-jobdefinition-containerproperties.html#cfn-batch-jobdefinition-containerproperties-memory).
983        ///
984        /// Update type: _Mutable_.
985        /// AWS CloudFormation doesn't replace the resource when you change this property.
986        pub memory: Option<::Value<u32>>,
987        /// Property [`MountPoints`](http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-batch-jobdefinition-containerproperties.html#cfn-batch-jobdefinition-containerproperties-mountpoints).
988        ///
989        /// Update type: _Mutable_.
990        /// AWS CloudFormation doesn't replace the resource when you change this property.
991        pub mount_points: Option<::ValueList<MountPoints>>,
992        /// Property [`NetworkConfiguration`](http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-batch-jobdefinition-containerproperties.html#cfn-batch-jobdefinition-containerproperties-networkconfiguration).
993        ///
994        /// Update type: _Mutable_.
995        /// AWS CloudFormation doesn't replace the resource when you change this property.
996        pub network_configuration: Option<::Value<NetworkConfiguration>>,
997        /// Property [`Privileged`](http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-batch-jobdefinition-containerproperties.html#cfn-batch-jobdefinition-containerproperties-privileged).
998        ///
999        /// Update type: _Mutable_.
1000        /// AWS CloudFormation doesn't replace the resource when you change this property.
1001        pub privileged: Option<::Value<bool>>,
1002        /// Property [`ReadonlyRootFilesystem`](http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-batch-jobdefinition-containerproperties.html#cfn-batch-jobdefinition-containerproperties-readonlyrootfilesystem).
1003        ///
1004        /// Update type: _Mutable_.
1005        /// AWS CloudFormation doesn't replace the resource when you change this property.
1006        pub readonly_root_filesystem: Option<::Value<bool>>,
1007        /// Property [`ResourceRequirements`](http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-batch-jobdefinition-containerproperties.html#cfn-batch-jobdefinition-containerproperties-resourcerequirements).
1008        ///
1009        /// Update type: _Mutable_.
1010        /// AWS CloudFormation doesn't replace the resource when you change this property.
1011        pub resource_requirements: Option<::ValueList<ResourceRequirement>>,
1012        /// Property [`Secrets`](http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-batch-jobdefinition-containerproperties.html#cfn-batch-jobdefinition-containerproperties-secrets).
1013        ///
1014        /// Update type: _Mutable_.
1015        /// AWS CloudFormation doesn't replace the resource when you change this property.
1016        pub secrets: Option<::ValueList<Secret>>,
1017        /// Property [`Ulimits`](http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-batch-jobdefinition-containerproperties.html#cfn-batch-jobdefinition-containerproperties-ulimits).
1018        ///
1019        /// Update type: _Mutable_.
1020        /// AWS CloudFormation doesn't replace the resource when you change this property.
1021        pub ulimits: Option<::ValueList<Ulimit>>,
1022        /// Property [`User`](http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-batch-jobdefinition-containerproperties.html#cfn-batch-jobdefinition-containerproperties-user).
1023        ///
1024        /// Update type: _Mutable_.
1025        /// AWS CloudFormation doesn't replace the resource when you change this property.
1026        pub user: Option<::Value<String>>,
1027        /// Property [`Vcpus`](http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-batch-jobdefinition-containerproperties.html#cfn-batch-jobdefinition-containerproperties-vcpus).
1028        ///
1029        /// Update type: _Mutable_.
1030        /// AWS CloudFormation doesn't replace the resource when you change this property.
1031        pub vcpus: Option<::Value<u32>>,
1032        /// Property [`Volumes`](http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-batch-jobdefinition-containerproperties.html#cfn-batch-jobdefinition-containerproperties-volumes).
1033        ///
1034        /// Update type: _Mutable_.
1035        /// AWS CloudFormation doesn't replace the resource when you change this property.
1036        pub volumes: Option<::ValueList<Volumes>>,
1037    }
1038
1039    impl ::codec::SerializeValue for ContainerProperties {
1040        fn serialize<S: ::serde::Serializer>(&self, s: S) -> Result<S::Ok, S::Error> {
1041            let mut map = ::serde::Serializer::serialize_map(s, None)?;
1042            if let Some(ref command) = self.command {
1043                ::serde::ser::SerializeMap::serialize_entry(&mut map, "Command", command)?;
1044            }
1045            if let Some(ref environment) = self.environment {
1046                ::serde::ser::SerializeMap::serialize_entry(&mut map, "Environment", environment)?;
1047            }
1048            if let Some(ref execution_role_arn) = self.execution_role_arn {
1049                ::serde::ser::SerializeMap::serialize_entry(&mut map, "ExecutionRoleArn", execution_role_arn)?;
1050            }
1051            if let Some(ref fargate_platform_configuration) = self.fargate_platform_configuration {
1052                ::serde::ser::SerializeMap::serialize_entry(&mut map, "FargatePlatformConfiguration", fargate_platform_configuration)?;
1053            }
1054            ::serde::ser::SerializeMap::serialize_entry(&mut map, "Image", &self.image)?;
1055            if let Some(ref instance_type) = self.instance_type {
1056                ::serde::ser::SerializeMap::serialize_entry(&mut map, "InstanceType", instance_type)?;
1057            }
1058            if let Some(ref job_role_arn) = self.job_role_arn {
1059                ::serde::ser::SerializeMap::serialize_entry(&mut map, "JobRoleArn", job_role_arn)?;
1060            }
1061            if let Some(ref linux_parameters) = self.linux_parameters {
1062                ::serde::ser::SerializeMap::serialize_entry(&mut map, "LinuxParameters", linux_parameters)?;
1063            }
1064            if let Some(ref log_configuration) = self.log_configuration {
1065                ::serde::ser::SerializeMap::serialize_entry(&mut map, "LogConfiguration", log_configuration)?;
1066            }
1067            if let Some(ref memory) = self.memory {
1068                ::serde::ser::SerializeMap::serialize_entry(&mut map, "Memory", memory)?;
1069            }
1070            if let Some(ref mount_points) = self.mount_points {
1071                ::serde::ser::SerializeMap::serialize_entry(&mut map, "MountPoints", mount_points)?;
1072            }
1073            if let Some(ref network_configuration) = self.network_configuration {
1074                ::serde::ser::SerializeMap::serialize_entry(&mut map, "NetworkConfiguration", network_configuration)?;
1075            }
1076            if let Some(ref privileged) = self.privileged {
1077                ::serde::ser::SerializeMap::serialize_entry(&mut map, "Privileged", privileged)?;
1078            }
1079            if let Some(ref readonly_root_filesystem) = self.readonly_root_filesystem {
1080                ::serde::ser::SerializeMap::serialize_entry(&mut map, "ReadonlyRootFilesystem", readonly_root_filesystem)?;
1081            }
1082            if let Some(ref resource_requirements) = self.resource_requirements {
1083                ::serde::ser::SerializeMap::serialize_entry(&mut map, "ResourceRequirements", resource_requirements)?;
1084            }
1085            if let Some(ref secrets) = self.secrets {
1086                ::serde::ser::SerializeMap::serialize_entry(&mut map, "Secrets", secrets)?;
1087            }
1088            if let Some(ref ulimits) = self.ulimits {
1089                ::serde::ser::SerializeMap::serialize_entry(&mut map, "Ulimits", ulimits)?;
1090            }
1091            if let Some(ref user) = self.user {
1092                ::serde::ser::SerializeMap::serialize_entry(&mut map, "User", user)?;
1093            }
1094            if let Some(ref vcpus) = self.vcpus {
1095                ::serde::ser::SerializeMap::serialize_entry(&mut map, "Vcpus", vcpus)?;
1096            }
1097            if let Some(ref volumes) = self.volumes {
1098                ::serde::ser::SerializeMap::serialize_entry(&mut map, "Volumes", volumes)?;
1099            }
1100            ::serde::ser::SerializeMap::end(map)
1101        }
1102    }
1103
1104    impl ::codec::DeserializeValue for ContainerProperties {
1105        fn deserialize<'de, D: ::serde::Deserializer<'de>>(d: D) -> Result<ContainerProperties, D::Error> {
1106            struct Visitor;
1107
1108            impl<'de> ::serde::de::Visitor<'de> for Visitor {
1109                type Value = ContainerProperties;
1110
1111                fn expecting(&self, f: &mut ::std::fmt::Formatter) -> ::std::fmt::Result {
1112                    write!(f, "a struct of type ContainerProperties")
1113                }
1114
1115                fn visit_map<A: ::serde::de::MapAccess<'de>>(self, mut map: A) -> Result<Self::Value, A::Error> {
1116                    let mut command: Option<::ValueList<String>> = None;
1117                    let mut environment: Option<::ValueList<Environment>> = None;
1118                    let mut execution_role_arn: Option<::Value<String>> = None;
1119                    let mut fargate_platform_configuration: Option<::Value<FargatePlatformConfiguration>> = None;
1120                    let mut image: Option<::Value<String>> = None;
1121                    let mut instance_type: Option<::Value<String>> = None;
1122                    let mut job_role_arn: Option<::Value<String>> = None;
1123                    let mut linux_parameters: Option<::Value<LinuxParameters>> = None;
1124                    let mut log_configuration: Option<::Value<LogConfiguration>> = None;
1125                    let mut memory: Option<::Value<u32>> = None;
1126                    let mut mount_points: Option<::ValueList<MountPoints>> = None;
1127                    let mut network_configuration: Option<::Value<NetworkConfiguration>> = None;
1128                    let mut privileged: Option<::Value<bool>> = None;
1129                    let mut readonly_root_filesystem: Option<::Value<bool>> = None;
1130                    let mut resource_requirements: Option<::ValueList<ResourceRequirement>> = None;
1131                    let mut secrets: Option<::ValueList<Secret>> = None;
1132                    let mut ulimits: Option<::ValueList<Ulimit>> = None;
1133                    let mut user: Option<::Value<String>> = None;
1134                    let mut vcpus: Option<::Value<u32>> = None;
1135                    let mut volumes: Option<::ValueList<Volumes>> = None;
1136
1137                    while let Some(__cfn_key) = ::serde::de::MapAccess::next_key::<String>(&mut map)? {
1138                        match __cfn_key.as_ref() {
1139                            "Command" => {
1140                                command = ::serde::de::MapAccess::next_value(&mut map)?;
1141                            }
1142                            "Environment" => {
1143                                environment = ::serde::de::MapAccess::next_value(&mut map)?;
1144                            }
1145                            "ExecutionRoleArn" => {
1146                                execution_role_arn = ::serde::de::MapAccess::next_value(&mut map)?;
1147                            }
1148                            "FargatePlatformConfiguration" => {
1149                                fargate_platform_configuration = ::serde::de::MapAccess::next_value(&mut map)?;
1150                            }
1151                            "Image" => {
1152                                image = ::serde::de::MapAccess::next_value(&mut map)?;
1153                            }
1154                            "InstanceType" => {
1155                                instance_type = ::serde::de::MapAccess::next_value(&mut map)?;
1156                            }
1157                            "JobRoleArn" => {
1158                                job_role_arn = ::serde::de::MapAccess::next_value(&mut map)?;
1159                            }
1160                            "LinuxParameters" => {
1161                                linux_parameters = ::serde::de::MapAccess::next_value(&mut map)?;
1162                            }
1163                            "LogConfiguration" => {
1164                                log_configuration = ::serde::de::MapAccess::next_value(&mut map)?;
1165                            }
1166                            "Memory" => {
1167                                memory = ::serde::de::MapAccess::next_value(&mut map)?;
1168                            }
1169                            "MountPoints" => {
1170                                mount_points = ::serde::de::MapAccess::next_value(&mut map)?;
1171                            }
1172                            "NetworkConfiguration" => {
1173                                network_configuration = ::serde::de::MapAccess::next_value(&mut map)?;
1174                            }
1175                            "Privileged" => {
1176                                privileged = ::serde::de::MapAccess::next_value(&mut map)?;
1177                            }
1178                            "ReadonlyRootFilesystem" => {
1179                                readonly_root_filesystem = ::serde::de::MapAccess::next_value(&mut map)?;
1180                            }
1181                            "ResourceRequirements" => {
1182                                resource_requirements = ::serde::de::MapAccess::next_value(&mut map)?;
1183                            }
1184                            "Secrets" => {
1185                                secrets = ::serde::de::MapAccess::next_value(&mut map)?;
1186                            }
1187                            "Ulimits" => {
1188                                ulimits = ::serde::de::MapAccess::next_value(&mut map)?;
1189                            }
1190                            "User" => {
1191                                user = ::serde::de::MapAccess::next_value(&mut map)?;
1192                            }
1193                            "Vcpus" => {
1194                                vcpus = ::serde::de::MapAccess::next_value(&mut map)?;
1195                            }
1196                            "Volumes" => {
1197                                volumes = ::serde::de::MapAccess::next_value(&mut map)?;
1198                            }
1199                            _ => {}
1200                        }
1201                    }
1202
1203                    Ok(ContainerProperties {
1204                        command: command,
1205                        environment: environment,
1206                        execution_role_arn: execution_role_arn,
1207                        fargate_platform_configuration: fargate_platform_configuration,
1208                        image: image.ok_or(::serde::de::Error::missing_field("Image"))?,
1209                        instance_type: instance_type,
1210                        job_role_arn: job_role_arn,
1211                        linux_parameters: linux_parameters,
1212                        log_configuration: log_configuration,
1213                        memory: memory,
1214                        mount_points: mount_points,
1215                        network_configuration: network_configuration,
1216                        privileged: privileged,
1217                        readonly_root_filesystem: readonly_root_filesystem,
1218                        resource_requirements: resource_requirements,
1219                        secrets: secrets,
1220                        ulimits: ulimits,
1221                        user: user,
1222                        vcpus: vcpus,
1223                        volumes: volumes,
1224                    })
1225                }
1226            }
1227
1228            d.deserialize_map(Visitor)
1229        }
1230    }
1231
1232    /// The [`AWS::Batch::JobDefinition.Device`](http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-batch-jobdefinition-device.html) property type.
1233    #[derive(Debug, Default)]
1234    pub struct Device {
1235        /// Property [`ContainerPath`](http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-batch-jobdefinition-device.html#cfn-batch-jobdefinition-device-containerpath).
1236        ///
1237        /// Update type: _Mutable_.
1238        /// AWS CloudFormation doesn't replace the resource when you change this property.
1239        pub container_path: Option<::Value<String>>,
1240        /// Property [`HostPath`](http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-batch-jobdefinition-device.html#cfn-batch-jobdefinition-device-hostpath).
1241        ///
1242        /// Update type: _Mutable_.
1243        /// AWS CloudFormation doesn't replace the resource when you change this property.
1244        pub host_path: Option<::Value<String>>,
1245        /// Property [`Permissions`](http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-batch-jobdefinition-device.html#cfn-batch-jobdefinition-device-permissions).
1246        ///
1247        /// Update type: _Mutable_.
1248        /// AWS CloudFormation doesn't replace the resource when you change this property.
1249        pub permissions: Option<::ValueList<String>>,
1250    }
1251
1252    impl ::codec::SerializeValue for Device {
1253        fn serialize<S: ::serde::Serializer>(&self, s: S) -> Result<S::Ok, S::Error> {
1254            let mut map = ::serde::Serializer::serialize_map(s, None)?;
1255            if let Some(ref container_path) = self.container_path {
1256                ::serde::ser::SerializeMap::serialize_entry(&mut map, "ContainerPath", container_path)?;
1257            }
1258            if let Some(ref host_path) = self.host_path {
1259                ::serde::ser::SerializeMap::serialize_entry(&mut map, "HostPath", host_path)?;
1260            }
1261            if let Some(ref permissions) = self.permissions {
1262                ::serde::ser::SerializeMap::serialize_entry(&mut map, "Permissions", permissions)?;
1263            }
1264            ::serde::ser::SerializeMap::end(map)
1265        }
1266    }
1267
1268    impl ::codec::DeserializeValue for Device {
1269        fn deserialize<'de, D: ::serde::Deserializer<'de>>(d: D) -> Result<Device, D::Error> {
1270            struct Visitor;
1271
1272            impl<'de> ::serde::de::Visitor<'de> for Visitor {
1273                type Value = Device;
1274
1275                fn expecting(&self, f: &mut ::std::fmt::Formatter) -> ::std::fmt::Result {
1276                    write!(f, "a struct of type Device")
1277                }
1278
1279                fn visit_map<A: ::serde::de::MapAccess<'de>>(self, mut map: A) -> Result<Self::Value, A::Error> {
1280                    let mut container_path: Option<::Value<String>> = None;
1281                    let mut host_path: Option<::Value<String>> = None;
1282                    let mut permissions: Option<::ValueList<String>> = None;
1283
1284                    while let Some(__cfn_key) = ::serde::de::MapAccess::next_key::<String>(&mut map)? {
1285                        match __cfn_key.as_ref() {
1286                            "ContainerPath" => {
1287                                container_path = ::serde::de::MapAccess::next_value(&mut map)?;
1288                            }
1289                            "HostPath" => {
1290                                host_path = ::serde::de::MapAccess::next_value(&mut map)?;
1291                            }
1292                            "Permissions" => {
1293                                permissions = ::serde::de::MapAccess::next_value(&mut map)?;
1294                            }
1295                            _ => {}
1296                        }
1297                    }
1298
1299                    Ok(Device {
1300                        container_path: container_path,
1301                        host_path: host_path,
1302                        permissions: permissions,
1303                    })
1304                }
1305            }
1306
1307            d.deserialize_map(Visitor)
1308        }
1309    }
1310
1311    /// The [`AWS::Batch::JobDefinition.EfsVolumeConfiguration`](http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-batch-jobdefinition-efsvolumeconfiguration.html) property type.
1312    #[derive(Debug, Default)]
1313    pub struct EfsVolumeConfiguration {
1314        /// Property [`AuthorizationConfig`](http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-batch-jobdefinition-efsvolumeconfiguration.html#cfn-batch-jobdefinition-efsvolumeconfiguration-authorizationconfig).
1315        ///
1316        /// Update type: _Mutable_.
1317        /// AWS CloudFormation doesn't replace the resource when you change this property.
1318        pub authorization_config: Option<::Value<AuthorizationConfig>>,
1319        /// Property [`FileSystemId`](http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-batch-jobdefinition-efsvolumeconfiguration.html#cfn-batch-jobdefinition-efsvolumeconfiguration-filesystemid).
1320        ///
1321        /// Update type: _Mutable_.
1322        /// AWS CloudFormation doesn't replace the resource when you change this property.
1323        pub file_system_id: ::Value<String>,
1324        /// Property [`RootDirectory`](http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-batch-jobdefinition-efsvolumeconfiguration.html#cfn-batch-jobdefinition-efsvolumeconfiguration-rootdirectory).
1325        ///
1326        /// Update type: _Mutable_.
1327        /// AWS CloudFormation doesn't replace the resource when you change this property.
1328        pub root_directory: Option<::Value<String>>,
1329        /// Property [`TransitEncryption`](http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-batch-jobdefinition-efsvolumeconfiguration.html#cfn-batch-jobdefinition-efsvolumeconfiguration-transitencryption).
1330        ///
1331        /// Update type: _Mutable_.
1332        /// AWS CloudFormation doesn't replace the resource when you change this property.
1333        pub transit_encryption: Option<::Value<String>>,
1334        /// Property [`TransitEncryptionPort`](http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-batch-jobdefinition-efsvolumeconfiguration.html#cfn-batch-jobdefinition-efsvolumeconfiguration-transitencryptionport).
1335        ///
1336        /// Update type: _Mutable_.
1337        /// AWS CloudFormation doesn't replace the resource when you change this property.
1338        pub transit_encryption_port: Option<::Value<u32>>,
1339    }
1340
1341    impl ::codec::SerializeValue for EfsVolumeConfiguration {
1342        fn serialize<S: ::serde::Serializer>(&self, s: S) -> Result<S::Ok, S::Error> {
1343            let mut map = ::serde::Serializer::serialize_map(s, None)?;
1344            if let Some(ref authorization_config) = self.authorization_config {
1345                ::serde::ser::SerializeMap::serialize_entry(&mut map, "AuthorizationConfig", authorization_config)?;
1346            }
1347            ::serde::ser::SerializeMap::serialize_entry(&mut map, "FileSystemId", &self.file_system_id)?;
1348            if let Some(ref root_directory) = self.root_directory {
1349                ::serde::ser::SerializeMap::serialize_entry(&mut map, "RootDirectory", root_directory)?;
1350            }
1351            if let Some(ref transit_encryption) = self.transit_encryption {
1352                ::serde::ser::SerializeMap::serialize_entry(&mut map, "TransitEncryption", transit_encryption)?;
1353            }
1354            if let Some(ref transit_encryption_port) = self.transit_encryption_port {
1355                ::serde::ser::SerializeMap::serialize_entry(&mut map, "TransitEncryptionPort", transit_encryption_port)?;
1356            }
1357            ::serde::ser::SerializeMap::end(map)
1358        }
1359    }
1360
1361    impl ::codec::DeserializeValue for EfsVolumeConfiguration {
1362        fn deserialize<'de, D: ::serde::Deserializer<'de>>(d: D) -> Result<EfsVolumeConfiguration, D::Error> {
1363            struct Visitor;
1364
1365            impl<'de> ::serde::de::Visitor<'de> for Visitor {
1366                type Value = EfsVolumeConfiguration;
1367
1368                fn expecting(&self, f: &mut ::std::fmt::Formatter) -> ::std::fmt::Result {
1369                    write!(f, "a struct of type EfsVolumeConfiguration")
1370                }
1371
1372                fn visit_map<A: ::serde::de::MapAccess<'de>>(self, mut map: A) -> Result<Self::Value, A::Error> {
1373                    let mut authorization_config: Option<::Value<AuthorizationConfig>> = None;
1374                    let mut file_system_id: Option<::Value<String>> = None;
1375                    let mut root_directory: Option<::Value<String>> = None;
1376                    let mut transit_encryption: Option<::Value<String>> = None;
1377                    let mut transit_encryption_port: Option<::Value<u32>> = None;
1378
1379                    while let Some(__cfn_key) = ::serde::de::MapAccess::next_key::<String>(&mut map)? {
1380                        match __cfn_key.as_ref() {
1381                            "AuthorizationConfig" => {
1382                                authorization_config = ::serde::de::MapAccess::next_value(&mut map)?;
1383                            }
1384                            "FileSystemId" => {
1385                                file_system_id = ::serde::de::MapAccess::next_value(&mut map)?;
1386                            }
1387                            "RootDirectory" => {
1388                                root_directory = ::serde::de::MapAccess::next_value(&mut map)?;
1389                            }
1390                            "TransitEncryption" => {
1391                                transit_encryption = ::serde::de::MapAccess::next_value(&mut map)?;
1392                            }
1393                            "TransitEncryptionPort" => {
1394                                transit_encryption_port = ::serde::de::MapAccess::next_value(&mut map)?;
1395                            }
1396                            _ => {}
1397                        }
1398                    }
1399
1400                    Ok(EfsVolumeConfiguration {
1401                        authorization_config: authorization_config,
1402                        file_system_id: file_system_id.ok_or(::serde::de::Error::missing_field("FileSystemId"))?,
1403                        root_directory: root_directory,
1404                        transit_encryption: transit_encryption,
1405                        transit_encryption_port: transit_encryption_port,
1406                    })
1407                }
1408            }
1409
1410            d.deserialize_map(Visitor)
1411        }
1412    }
1413
1414    /// The [`AWS::Batch::JobDefinition.Environment`](http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-batch-jobdefinition-environment.html) property type.
1415    #[derive(Debug, Default)]
1416    pub struct Environment {
1417        /// Property [`Name`](http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-batch-jobdefinition-environment.html#cfn-batch-jobdefinition-environment-name).
1418        ///
1419        /// Update type: _Mutable_.
1420        /// AWS CloudFormation doesn't replace the resource when you change this property.
1421        pub name: Option<::Value<String>>,
1422        /// Property [`Value`](http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-batch-jobdefinition-environment.html#cfn-batch-jobdefinition-environment-value).
1423        ///
1424        /// Update type: _Mutable_.
1425        /// AWS CloudFormation doesn't replace the resource when you change this property.
1426        pub value: Option<::Value<String>>,
1427    }
1428
1429    impl ::codec::SerializeValue for Environment {
1430        fn serialize<S: ::serde::Serializer>(&self, s: S) -> Result<S::Ok, S::Error> {
1431            let mut map = ::serde::Serializer::serialize_map(s, None)?;
1432            if let Some(ref name) = self.name {
1433                ::serde::ser::SerializeMap::serialize_entry(&mut map, "Name", name)?;
1434            }
1435            if let Some(ref value) = self.value {
1436                ::serde::ser::SerializeMap::serialize_entry(&mut map, "Value", value)?;
1437            }
1438            ::serde::ser::SerializeMap::end(map)
1439        }
1440    }
1441
1442    impl ::codec::DeserializeValue for Environment {
1443        fn deserialize<'de, D: ::serde::Deserializer<'de>>(d: D) -> Result<Environment, D::Error> {
1444            struct Visitor;
1445
1446            impl<'de> ::serde::de::Visitor<'de> for Visitor {
1447                type Value = Environment;
1448
1449                fn expecting(&self, f: &mut ::std::fmt::Formatter) -> ::std::fmt::Result {
1450                    write!(f, "a struct of type Environment")
1451                }
1452
1453                fn visit_map<A: ::serde::de::MapAccess<'de>>(self, mut map: A) -> Result<Self::Value, A::Error> {
1454                    let mut name: Option<::Value<String>> = None;
1455                    let mut value: Option<::Value<String>> = None;
1456
1457                    while let Some(__cfn_key) = ::serde::de::MapAccess::next_key::<String>(&mut map)? {
1458                        match __cfn_key.as_ref() {
1459                            "Name" => {
1460                                name = ::serde::de::MapAccess::next_value(&mut map)?;
1461                            }
1462                            "Value" => {
1463                                value = ::serde::de::MapAccess::next_value(&mut map)?;
1464                            }
1465                            _ => {}
1466                        }
1467                    }
1468
1469                    Ok(Environment {
1470                        name: name,
1471                        value: value,
1472                    })
1473                }
1474            }
1475
1476            d.deserialize_map(Visitor)
1477        }
1478    }
1479
1480    /// The [`AWS::Batch::JobDefinition.EvaluateOnExit`](http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-batch-jobdefinition-evaluateonexit.html) property type.
1481    #[derive(Debug, Default)]
1482    pub struct EvaluateOnExit {
1483        /// Property [`Action`](http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-batch-jobdefinition-evaluateonexit.html#cfn-batch-jobdefinition-evaluateonexit-action).
1484        ///
1485        /// Update type: _Mutable_.
1486        /// AWS CloudFormation doesn't replace the resource when you change this property.
1487        pub action: ::Value<String>,
1488        /// Property [`OnExitCode`](http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-batch-jobdefinition-evaluateonexit.html#cfn-batch-jobdefinition-evaluateonexit-onexitcode).
1489        ///
1490        /// Update type: _Mutable_.
1491        /// AWS CloudFormation doesn't replace the resource when you change this property.
1492        pub on_exit_code: Option<::Value<String>>,
1493        /// Property [`OnReason`](http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-batch-jobdefinition-evaluateonexit.html#cfn-batch-jobdefinition-evaluateonexit-onreason).
1494        ///
1495        /// Update type: _Mutable_.
1496        /// AWS CloudFormation doesn't replace the resource when you change this property.
1497        pub on_reason: Option<::Value<String>>,
1498        /// Property [`OnStatusReason`](http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-batch-jobdefinition-evaluateonexit.html#cfn-batch-jobdefinition-evaluateonexit-onstatusreason).
1499        ///
1500        /// Update type: _Mutable_.
1501        /// AWS CloudFormation doesn't replace the resource when you change this property.
1502        pub on_status_reason: Option<::Value<String>>,
1503    }
1504
1505    impl ::codec::SerializeValue for EvaluateOnExit {
1506        fn serialize<S: ::serde::Serializer>(&self, s: S) -> Result<S::Ok, S::Error> {
1507            let mut map = ::serde::Serializer::serialize_map(s, None)?;
1508            ::serde::ser::SerializeMap::serialize_entry(&mut map, "Action", &self.action)?;
1509            if let Some(ref on_exit_code) = self.on_exit_code {
1510                ::serde::ser::SerializeMap::serialize_entry(&mut map, "OnExitCode", on_exit_code)?;
1511            }
1512            if let Some(ref on_reason) = self.on_reason {
1513                ::serde::ser::SerializeMap::serialize_entry(&mut map, "OnReason", on_reason)?;
1514            }
1515            if let Some(ref on_status_reason) = self.on_status_reason {
1516                ::serde::ser::SerializeMap::serialize_entry(&mut map, "OnStatusReason", on_status_reason)?;
1517            }
1518            ::serde::ser::SerializeMap::end(map)
1519        }
1520    }
1521
1522    impl ::codec::DeserializeValue for EvaluateOnExit {
1523        fn deserialize<'de, D: ::serde::Deserializer<'de>>(d: D) -> Result<EvaluateOnExit, D::Error> {
1524            struct Visitor;
1525
1526            impl<'de> ::serde::de::Visitor<'de> for Visitor {
1527                type Value = EvaluateOnExit;
1528
1529                fn expecting(&self, f: &mut ::std::fmt::Formatter) -> ::std::fmt::Result {
1530                    write!(f, "a struct of type EvaluateOnExit")
1531                }
1532
1533                fn visit_map<A: ::serde::de::MapAccess<'de>>(self, mut map: A) -> Result<Self::Value, A::Error> {
1534                    let mut action: Option<::Value<String>> = None;
1535                    let mut on_exit_code: Option<::Value<String>> = None;
1536                    let mut on_reason: Option<::Value<String>> = None;
1537                    let mut on_status_reason: Option<::Value<String>> = None;
1538
1539                    while let Some(__cfn_key) = ::serde::de::MapAccess::next_key::<String>(&mut map)? {
1540                        match __cfn_key.as_ref() {
1541                            "Action" => {
1542                                action = ::serde::de::MapAccess::next_value(&mut map)?;
1543                            }
1544                            "OnExitCode" => {
1545                                on_exit_code = ::serde::de::MapAccess::next_value(&mut map)?;
1546                            }
1547                            "OnReason" => {
1548                                on_reason = ::serde::de::MapAccess::next_value(&mut map)?;
1549                            }
1550                            "OnStatusReason" => {
1551                                on_status_reason = ::serde::de::MapAccess::next_value(&mut map)?;
1552                            }
1553                            _ => {}
1554                        }
1555                    }
1556
1557                    Ok(EvaluateOnExit {
1558                        action: action.ok_or(::serde::de::Error::missing_field("Action"))?,
1559                        on_exit_code: on_exit_code,
1560                        on_reason: on_reason,
1561                        on_status_reason: on_status_reason,
1562                    })
1563                }
1564            }
1565
1566            d.deserialize_map(Visitor)
1567        }
1568    }
1569
1570    /// The [`AWS::Batch::JobDefinition.FargatePlatformConfiguration`](http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-batch-jobdefinition-containerproperties-fargateplatformconfiguration.html) property type.
1571    #[derive(Debug, Default)]
1572    pub struct FargatePlatformConfiguration {
1573        /// Property [`PlatformVersion`](http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-batch-jobdefinition-containerproperties-fargateplatformconfiguration.html#cfn-batch-jobdefinition-containerproperties-fargateplatformconfiguration-platformversion).
1574        ///
1575        /// Update type: _Mutable_.
1576        /// AWS CloudFormation doesn't replace the resource when you change this property.
1577        pub platform_version: Option<::Value<String>>,
1578    }
1579
1580    impl ::codec::SerializeValue for FargatePlatformConfiguration {
1581        fn serialize<S: ::serde::Serializer>(&self, s: S) -> Result<S::Ok, S::Error> {
1582            let mut map = ::serde::Serializer::serialize_map(s, None)?;
1583            if let Some(ref platform_version) = self.platform_version {
1584                ::serde::ser::SerializeMap::serialize_entry(&mut map, "PlatformVersion", platform_version)?;
1585            }
1586            ::serde::ser::SerializeMap::end(map)
1587        }
1588    }
1589
1590    impl ::codec::DeserializeValue for FargatePlatformConfiguration {
1591        fn deserialize<'de, D: ::serde::Deserializer<'de>>(d: D) -> Result<FargatePlatformConfiguration, D::Error> {
1592            struct Visitor;
1593
1594            impl<'de> ::serde::de::Visitor<'de> for Visitor {
1595                type Value = FargatePlatformConfiguration;
1596
1597                fn expecting(&self, f: &mut ::std::fmt::Formatter) -> ::std::fmt::Result {
1598                    write!(f, "a struct of type FargatePlatformConfiguration")
1599                }
1600
1601                fn visit_map<A: ::serde::de::MapAccess<'de>>(self, mut map: A) -> Result<Self::Value, A::Error> {
1602                    let mut platform_version: Option<::Value<String>> = None;
1603
1604                    while let Some(__cfn_key) = ::serde::de::MapAccess::next_key::<String>(&mut map)? {
1605                        match __cfn_key.as_ref() {
1606                            "PlatformVersion" => {
1607                                platform_version = ::serde::de::MapAccess::next_value(&mut map)?;
1608                            }
1609                            _ => {}
1610                        }
1611                    }
1612
1613                    Ok(FargatePlatformConfiguration {
1614                        platform_version: platform_version,
1615                    })
1616                }
1617            }
1618
1619            d.deserialize_map(Visitor)
1620        }
1621    }
1622
1623    /// The [`AWS::Batch::JobDefinition.LinuxParameters`](http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-batch-jobdefinition-containerproperties-linuxparameters.html) property type.
1624    #[derive(Debug, Default)]
1625    pub struct LinuxParameters {
1626        /// Property [`Devices`](http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-batch-jobdefinition-containerproperties-linuxparameters.html#cfn-batch-jobdefinition-containerproperties-linuxparameters-devices).
1627        ///
1628        /// Update type: _Mutable_.
1629        /// AWS CloudFormation doesn't replace the resource when you change this property.
1630        pub devices: Option<::ValueList<Device>>,
1631        /// Property [`InitProcessEnabled`](http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-batch-jobdefinition-containerproperties-linuxparameters.html#cfn-batch-jobdefinition-containerproperties-linuxparameters-initprocessenabled).
1632        ///
1633        /// Update type: _Mutable_.
1634        /// AWS CloudFormation doesn't replace the resource when you change this property.
1635        pub init_process_enabled: Option<::Value<bool>>,
1636        /// Property [`MaxSwap`](http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-batch-jobdefinition-containerproperties-linuxparameters.html#cfn-batch-jobdefinition-containerproperties-linuxparameters-maxswap).
1637        ///
1638        /// Update type: _Mutable_.
1639        /// AWS CloudFormation doesn't replace the resource when you change this property.
1640        pub max_swap: Option<::Value<u32>>,
1641        /// Property [`SharedMemorySize`](http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-batch-jobdefinition-containerproperties-linuxparameters.html#cfn-batch-jobdefinition-containerproperties-linuxparameters-sharedmemorysize).
1642        ///
1643        /// Update type: _Mutable_.
1644        /// AWS CloudFormation doesn't replace the resource when you change this property.
1645        pub shared_memory_size: Option<::Value<u32>>,
1646        /// Property [`Swappiness`](http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-batch-jobdefinition-containerproperties-linuxparameters.html#cfn-batch-jobdefinition-containerproperties-linuxparameters-swappiness).
1647        ///
1648        /// Update type: _Mutable_.
1649        /// AWS CloudFormation doesn't replace the resource when you change this property.
1650        pub swappiness: Option<::Value<u32>>,
1651        /// Property [`Tmpfs`](http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-batch-jobdefinition-containerproperties-linuxparameters.html#cfn-batch-jobdefinition-containerproperties-linuxparameters-tmpfs).
1652        ///
1653        /// Update type: _Mutable_.
1654        /// AWS CloudFormation doesn't replace the resource when you change this property.
1655        pub tmpfs: Option<::ValueList<Tmpfs>>,
1656    }
1657
1658    impl ::codec::SerializeValue for LinuxParameters {
1659        fn serialize<S: ::serde::Serializer>(&self, s: S) -> Result<S::Ok, S::Error> {
1660            let mut map = ::serde::Serializer::serialize_map(s, None)?;
1661            if let Some(ref devices) = self.devices {
1662                ::serde::ser::SerializeMap::serialize_entry(&mut map, "Devices", devices)?;
1663            }
1664            if let Some(ref init_process_enabled) = self.init_process_enabled {
1665                ::serde::ser::SerializeMap::serialize_entry(&mut map, "InitProcessEnabled", init_process_enabled)?;
1666            }
1667            if let Some(ref max_swap) = self.max_swap {
1668                ::serde::ser::SerializeMap::serialize_entry(&mut map, "MaxSwap", max_swap)?;
1669            }
1670            if let Some(ref shared_memory_size) = self.shared_memory_size {
1671                ::serde::ser::SerializeMap::serialize_entry(&mut map, "SharedMemorySize", shared_memory_size)?;
1672            }
1673            if let Some(ref swappiness) = self.swappiness {
1674                ::serde::ser::SerializeMap::serialize_entry(&mut map, "Swappiness", swappiness)?;
1675            }
1676            if let Some(ref tmpfs) = self.tmpfs {
1677                ::serde::ser::SerializeMap::serialize_entry(&mut map, "Tmpfs", tmpfs)?;
1678            }
1679            ::serde::ser::SerializeMap::end(map)
1680        }
1681    }
1682
1683    impl ::codec::DeserializeValue for LinuxParameters {
1684        fn deserialize<'de, D: ::serde::Deserializer<'de>>(d: D) -> Result<LinuxParameters, D::Error> {
1685            struct Visitor;
1686
1687            impl<'de> ::serde::de::Visitor<'de> for Visitor {
1688                type Value = LinuxParameters;
1689
1690                fn expecting(&self, f: &mut ::std::fmt::Formatter) -> ::std::fmt::Result {
1691                    write!(f, "a struct of type LinuxParameters")
1692                }
1693
1694                fn visit_map<A: ::serde::de::MapAccess<'de>>(self, mut map: A) -> Result<Self::Value, A::Error> {
1695                    let mut devices: Option<::ValueList<Device>> = None;
1696                    let mut init_process_enabled: Option<::Value<bool>> = None;
1697                    let mut max_swap: Option<::Value<u32>> = None;
1698                    let mut shared_memory_size: Option<::Value<u32>> = None;
1699                    let mut swappiness: Option<::Value<u32>> = None;
1700                    let mut tmpfs: Option<::ValueList<Tmpfs>> = None;
1701
1702                    while let Some(__cfn_key) = ::serde::de::MapAccess::next_key::<String>(&mut map)? {
1703                        match __cfn_key.as_ref() {
1704                            "Devices" => {
1705                                devices = ::serde::de::MapAccess::next_value(&mut map)?;
1706                            }
1707                            "InitProcessEnabled" => {
1708                                init_process_enabled = ::serde::de::MapAccess::next_value(&mut map)?;
1709                            }
1710                            "MaxSwap" => {
1711                                max_swap = ::serde::de::MapAccess::next_value(&mut map)?;
1712                            }
1713                            "SharedMemorySize" => {
1714                                shared_memory_size = ::serde::de::MapAccess::next_value(&mut map)?;
1715                            }
1716                            "Swappiness" => {
1717                                swappiness = ::serde::de::MapAccess::next_value(&mut map)?;
1718                            }
1719                            "Tmpfs" => {
1720                                tmpfs = ::serde::de::MapAccess::next_value(&mut map)?;
1721                            }
1722                            _ => {}
1723                        }
1724                    }
1725
1726                    Ok(LinuxParameters {
1727                        devices: devices,
1728                        init_process_enabled: init_process_enabled,
1729                        max_swap: max_swap,
1730                        shared_memory_size: shared_memory_size,
1731                        swappiness: swappiness,
1732                        tmpfs: tmpfs,
1733                    })
1734                }
1735            }
1736
1737            d.deserialize_map(Visitor)
1738        }
1739    }
1740
1741    /// The [`AWS::Batch::JobDefinition.LogConfiguration`](http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-batch-jobdefinition-containerproperties-logconfiguration.html) property type.
1742    #[derive(Debug, Default)]
1743    pub struct LogConfiguration {
1744        /// Property [`LogDriver`](http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-batch-jobdefinition-containerproperties-logconfiguration.html#cfn-batch-jobdefinition-containerproperties-logconfiguration-logdriver).
1745        ///
1746        /// Update type: _Mutable_.
1747        /// AWS CloudFormation doesn't replace the resource when you change this property.
1748        pub log_driver: ::Value<String>,
1749        /// Property [`Options`](http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-batch-jobdefinition-containerproperties-logconfiguration.html#cfn-batch-jobdefinition-containerproperties-logconfiguration-options).
1750        ///
1751        /// Update type: _Mutable_.
1752        /// AWS CloudFormation doesn't replace the resource when you change this property.
1753        pub options: Option<::Value<::json::Value>>,
1754        /// Property [`SecretOptions`](http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-batch-jobdefinition-containerproperties-logconfiguration.html#cfn-batch-jobdefinition-containerproperties-logconfiguration-secretoptions).
1755        ///
1756        /// Update type: _Mutable_.
1757        /// AWS CloudFormation doesn't replace the resource when you change this property.
1758        pub secret_options: Option<::ValueList<Secret>>,
1759    }
1760
1761    impl ::codec::SerializeValue for LogConfiguration {
1762        fn serialize<S: ::serde::Serializer>(&self, s: S) -> Result<S::Ok, S::Error> {
1763            let mut map = ::serde::Serializer::serialize_map(s, None)?;
1764            ::serde::ser::SerializeMap::serialize_entry(&mut map, "LogDriver", &self.log_driver)?;
1765            if let Some(ref options) = self.options {
1766                ::serde::ser::SerializeMap::serialize_entry(&mut map, "Options", options)?;
1767            }
1768            if let Some(ref secret_options) = self.secret_options {
1769                ::serde::ser::SerializeMap::serialize_entry(&mut map, "SecretOptions", secret_options)?;
1770            }
1771            ::serde::ser::SerializeMap::end(map)
1772        }
1773    }
1774
1775    impl ::codec::DeserializeValue for LogConfiguration {
1776        fn deserialize<'de, D: ::serde::Deserializer<'de>>(d: D) -> Result<LogConfiguration, D::Error> {
1777            struct Visitor;
1778
1779            impl<'de> ::serde::de::Visitor<'de> for Visitor {
1780                type Value = LogConfiguration;
1781
1782                fn expecting(&self, f: &mut ::std::fmt::Formatter) -> ::std::fmt::Result {
1783                    write!(f, "a struct of type LogConfiguration")
1784                }
1785
1786                fn visit_map<A: ::serde::de::MapAccess<'de>>(self, mut map: A) -> Result<Self::Value, A::Error> {
1787                    let mut log_driver: Option<::Value<String>> = None;
1788                    let mut options: Option<::Value<::json::Value>> = None;
1789                    let mut secret_options: Option<::ValueList<Secret>> = None;
1790
1791                    while let Some(__cfn_key) = ::serde::de::MapAccess::next_key::<String>(&mut map)? {
1792                        match __cfn_key.as_ref() {
1793                            "LogDriver" => {
1794                                log_driver = ::serde::de::MapAccess::next_value(&mut map)?;
1795                            }
1796                            "Options" => {
1797                                options = ::serde::de::MapAccess::next_value(&mut map)?;
1798                            }
1799                            "SecretOptions" => {
1800                                secret_options = ::serde::de::MapAccess::next_value(&mut map)?;
1801                            }
1802                            _ => {}
1803                        }
1804                    }
1805
1806                    Ok(LogConfiguration {
1807                        log_driver: log_driver.ok_or(::serde::de::Error::missing_field("LogDriver"))?,
1808                        options: options,
1809                        secret_options: secret_options,
1810                    })
1811                }
1812            }
1813
1814            d.deserialize_map(Visitor)
1815        }
1816    }
1817
1818    /// The [`AWS::Batch::JobDefinition.MountPoints`](http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-batch-jobdefinition-mountpoints.html) property type.
1819    #[derive(Debug, Default)]
1820    pub struct MountPoints {
1821        /// Property [`ContainerPath`](http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-batch-jobdefinition-mountpoints.html#cfn-batch-jobdefinition-mountpoints-containerpath).
1822        ///
1823        /// Update type: _Mutable_.
1824        /// AWS CloudFormation doesn't replace the resource when you change this property.
1825        pub container_path: Option<::Value<String>>,
1826        /// Property [`ReadOnly`](http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-batch-jobdefinition-mountpoints.html#cfn-batch-jobdefinition-mountpoints-readonly).
1827        ///
1828        /// Update type: _Mutable_.
1829        /// AWS CloudFormation doesn't replace the resource when you change this property.
1830        pub read_only: Option<::Value<bool>>,
1831        /// Property [`SourceVolume`](http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-batch-jobdefinition-mountpoints.html#cfn-batch-jobdefinition-mountpoints-sourcevolume).
1832        ///
1833        /// Update type: _Mutable_.
1834        /// AWS CloudFormation doesn't replace the resource when you change this property.
1835        pub source_volume: Option<::Value<String>>,
1836    }
1837
1838    impl ::codec::SerializeValue for MountPoints {
1839        fn serialize<S: ::serde::Serializer>(&self, s: S) -> Result<S::Ok, S::Error> {
1840            let mut map = ::serde::Serializer::serialize_map(s, None)?;
1841            if let Some(ref container_path) = self.container_path {
1842                ::serde::ser::SerializeMap::serialize_entry(&mut map, "ContainerPath", container_path)?;
1843            }
1844            if let Some(ref read_only) = self.read_only {
1845                ::serde::ser::SerializeMap::serialize_entry(&mut map, "ReadOnly", read_only)?;
1846            }
1847            if let Some(ref source_volume) = self.source_volume {
1848                ::serde::ser::SerializeMap::serialize_entry(&mut map, "SourceVolume", source_volume)?;
1849            }
1850            ::serde::ser::SerializeMap::end(map)
1851        }
1852    }
1853
1854    impl ::codec::DeserializeValue for MountPoints {
1855        fn deserialize<'de, D: ::serde::Deserializer<'de>>(d: D) -> Result<MountPoints, D::Error> {
1856            struct Visitor;
1857
1858            impl<'de> ::serde::de::Visitor<'de> for Visitor {
1859                type Value = MountPoints;
1860
1861                fn expecting(&self, f: &mut ::std::fmt::Formatter) -> ::std::fmt::Result {
1862                    write!(f, "a struct of type MountPoints")
1863                }
1864
1865                fn visit_map<A: ::serde::de::MapAccess<'de>>(self, mut map: A) -> Result<Self::Value, A::Error> {
1866                    let mut container_path: Option<::Value<String>> = None;
1867                    let mut read_only: Option<::Value<bool>> = None;
1868                    let mut source_volume: Option<::Value<String>> = None;
1869
1870                    while let Some(__cfn_key) = ::serde::de::MapAccess::next_key::<String>(&mut map)? {
1871                        match __cfn_key.as_ref() {
1872                            "ContainerPath" => {
1873                                container_path = ::serde::de::MapAccess::next_value(&mut map)?;
1874                            }
1875                            "ReadOnly" => {
1876                                read_only = ::serde::de::MapAccess::next_value(&mut map)?;
1877                            }
1878                            "SourceVolume" => {
1879                                source_volume = ::serde::de::MapAccess::next_value(&mut map)?;
1880                            }
1881                            _ => {}
1882                        }
1883                    }
1884
1885                    Ok(MountPoints {
1886                        container_path: container_path,
1887                        read_only: read_only,
1888                        source_volume: source_volume,
1889                    })
1890                }
1891            }
1892
1893            d.deserialize_map(Visitor)
1894        }
1895    }
1896
1897    /// The [`AWS::Batch::JobDefinition.NetworkConfiguration`](http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-batch-jobdefinition-containerproperties-networkconfiguration.html) property type.
1898    #[derive(Debug, Default)]
1899    pub struct NetworkConfiguration {
1900        /// Property [`AssignPublicIp`](http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-batch-jobdefinition-containerproperties-networkconfiguration.html#cfn-batch-jobdefinition-containerproperties-networkconfiguration-assignpublicip).
1901        ///
1902        /// Update type: _Mutable_.
1903        /// AWS CloudFormation doesn't replace the resource when you change this property.
1904        pub assign_public_ip: Option<::Value<String>>,
1905    }
1906
1907    impl ::codec::SerializeValue for NetworkConfiguration {
1908        fn serialize<S: ::serde::Serializer>(&self, s: S) -> Result<S::Ok, S::Error> {
1909            let mut map = ::serde::Serializer::serialize_map(s, None)?;
1910            if let Some(ref assign_public_ip) = self.assign_public_ip {
1911                ::serde::ser::SerializeMap::serialize_entry(&mut map, "AssignPublicIp", assign_public_ip)?;
1912            }
1913            ::serde::ser::SerializeMap::end(map)
1914        }
1915    }
1916
1917    impl ::codec::DeserializeValue for NetworkConfiguration {
1918        fn deserialize<'de, D: ::serde::Deserializer<'de>>(d: D) -> Result<NetworkConfiguration, D::Error> {
1919            struct Visitor;
1920
1921            impl<'de> ::serde::de::Visitor<'de> for Visitor {
1922                type Value = NetworkConfiguration;
1923
1924                fn expecting(&self, f: &mut ::std::fmt::Formatter) -> ::std::fmt::Result {
1925                    write!(f, "a struct of type NetworkConfiguration")
1926                }
1927
1928                fn visit_map<A: ::serde::de::MapAccess<'de>>(self, mut map: A) -> Result<Self::Value, A::Error> {
1929                    let mut assign_public_ip: Option<::Value<String>> = None;
1930
1931                    while let Some(__cfn_key) = ::serde::de::MapAccess::next_key::<String>(&mut map)? {
1932                        match __cfn_key.as_ref() {
1933                            "AssignPublicIp" => {
1934                                assign_public_ip = ::serde::de::MapAccess::next_value(&mut map)?;
1935                            }
1936                            _ => {}
1937                        }
1938                    }
1939
1940                    Ok(NetworkConfiguration {
1941                        assign_public_ip: assign_public_ip,
1942                    })
1943                }
1944            }
1945
1946            d.deserialize_map(Visitor)
1947        }
1948    }
1949
1950    /// The [`AWS::Batch::JobDefinition.NodeProperties`](http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-batch-jobdefinition-nodeproperties.html) property type.
1951    #[derive(Debug, Default)]
1952    pub struct NodeProperties {
1953        /// Property [`MainNode`](http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-batch-jobdefinition-nodeproperties.html#cfn-batch-jobdefinition-nodeproperties-mainnode).
1954        ///
1955        /// Update type: _Mutable_.
1956        /// AWS CloudFormation doesn't replace the resource when you change this property.
1957        pub main_node: ::Value<u32>,
1958        /// Property [`NodeRangeProperties`](http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-batch-jobdefinition-nodeproperties.html#cfn-batch-jobdefinition-nodeproperties-noderangeproperties).
1959        ///
1960        /// Update type: _Mutable_.
1961        /// AWS CloudFormation doesn't replace the resource when you change this property.
1962        pub node_range_properties: ::ValueList<NodeRangeProperty>,
1963        /// Property [`NumNodes`](http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-batch-jobdefinition-nodeproperties.html#cfn-batch-jobdefinition-nodeproperties-numnodes).
1964        ///
1965        /// Update type: _Mutable_.
1966        /// AWS CloudFormation doesn't replace the resource when you change this property.
1967        pub num_nodes: ::Value<u32>,
1968    }
1969
1970    impl ::codec::SerializeValue for NodeProperties {
1971        fn serialize<S: ::serde::Serializer>(&self, s: S) -> Result<S::Ok, S::Error> {
1972            let mut map = ::serde::Serializer::serialize_map(s, None)?;
1973            ::serde::ser::SerializeMap::serialize_entry(&mut map, "MainNode", &self.main_node)?;
1974            ::serde::ser::SerializeMap::serialize_entry(&mut map, "NodeRangeProperties", &self.node_range_properties)?;
1975            ::serde::ser::SerializeMap::serialize_entry(&mut map, "NumNodes", &self.num_nodes)?;
1976            ::serde::ser::SerializeMap::end(map)
1977        }
1978    }
1979
1980    impl ::codec::DeserializeValue for NodeProperties {
1981        fn deserialize<'de, D: ::serde::Deserializer<'de>>(d: D) -> Result<NodeProperties, D::Error> {
1982            struct Visitor;
1983
1984            impl<'de> ::serde::de::Visitor<'de> for Visitor {
1985                type Value = NodeProperties;
1986
1987                fn expecting(&self, f: &mut ::std::fmt::Formatter) -> ::std::fmt::Result {
1988                    write!(f, "a struct of type NodeProperties")
1989                }
1990
1991                fn visit_map<A: ::serde::de::MapAccess<'de>>(self, mut map: A) -> Result<Self::Value, A::Error> {
1992                    let mut main_node: Option<::Value<u32>> = None;
1993                    let mut node_range_properties: Option<::ValueList<NodeRangeProperty>> = None;
1994                    let mut num_nodes: Option<::Value<u32>> = None;
1995
1996                    while let Some(__cfn_key) = ::serde::de::MapAccess::next_key::<String>(&mut map)? {
1997                        match __cfn_key.as_ref() {
1998                            "MainNode" => {
1999                                main_node = ::serde::de::MapAccess::next_value(&mut map)?;
2000                            }
2001                            "NodeRangeProperties" => {
2002                                node_range_properties = ::serde::de::MapAccess::next_value(&mut map)?;
2003                            }
2004                            "NumNodes" => {
2005                                num_nodes = ::serde::de::MapAccess::next_value(&mut map)?;
2006                            }
2007                            _ => {}
2008                        }
2009                    }
2010
2011                    Ok(NodeProperties {
2012                        main_node: main_node.ok_or(::serde::de::Error::missing_field("MainNode"))?,
2013                        node_range_properties: node_range_properties.ok_or(::serde::de::Error::missing_field("NodeRangeProperties"))?,
2014                        num_nodes: num_nodes.ok_or(::serde::de::Error::missing_field("NumNodes"))?,
2015                    })
2016                }
2017            }
2018
2019            d.deserialize_map(Visitor)
2020        }
2021    }
2022
2023    /// The [`AWS::Batch::JobDefinition.NodeRangeProperty`](http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-batch-jobdefinition-noderangeproperty.html) property type.
2024    #[derive(Debug, Default)]
2025    pub struct NodeRangeProperty {
2026        /// Property [`Container`](http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-batch-jobdefinition-noderangeproperty.html#cfn-batch-jobdefinition-noderangeproperty-container).
2027        ///
2028        /// Update type: _Mutable_.
2029        /// AWS CloudFormation doesn't replace the resource when you change this property.
2030        pub container: Option<::Value<ContainerProperties>>,
2031        /// Property [`TargetNodes`](http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-batch-jobdefinition-noderangeproperty.html#cfn-batch-jobdefinition-noderangeproperty-targetnodes).
2032        ///
2033        /// Update type: _Mutable_.
2034        /// AWS CloudFormation doesn't replace the resource when you change this property.
2035        pub target_nodes: ::Value<String>,
2036    }
2037
2038    impl ::codec::SerializeValue for NodeRangeProperty {
2039        fn serialize<S: ::serde::Serializer>(&self, s: S) -> Result<S::Ok, S::Error> {
2040            let mut map = ::serde::Serializer::serialize_map(s, None)?;
2041            if let Some(ref container) = self.container {
2042                ::serde::ser::SerializeMap::serialize_entry(&mut map, "Container", container)?;
2043            }
2044            ::serde::ser::SerializeMap::serialize_entry(&mut map, "TargetNodes", &self.target_nodes)?;
2045            ::serde::ser::SerializeMap::end(map)
2046        }
2047    }
2048
2049    impl ::codec::DeserializeValue for NodeRangeProperty {
2050        fn deserialize<'de, D: ::serde::Deserializer<'de>>(d: D) -> Result<NodeRangeProperty, D::Error> {
2051            struct Visitor;
2052
2053            impl<'de> ::serde::de::Visitor<'de> for Visitor {
2054                type Value = NodeRangeProperty;
2055
2056                fn expecting(&self, f: &mut ::std::fmt::Formatter) -> ::std::fmt::Result {
2057                    write!(f, "a struct of type NodeRangeProperty")
2058                }
2059
2060                fn visit_map<A: ::serde::de::MapAccess<'de>>(self, mut map: A) -> Result<Self::Value, A::Error> {
2061                    let mut container: Option<::Value<ContainerProperties>> = None;
2062                    let mut target_nodes: Option<::Value<String>> = None;
2063
2064                    while let Some(__cfn_key) = ::serde::de::MapAccess::next_key::<String>(&mut map)? {
2065                        match __cfn_key.as_ref() {
2066                            "Container" => {
2067                                container = ::serde::de::MapAccess::next_value(&mut map)?;
2068                            }
2069                            "TargetNodes" => {
2070                                target_nodes = ::serde::de::MapAccess::next_value(&mut map)?;
2071                            }
2072                            _ => {}
2073                        }
2074                    }
2075
2076                    Ok(NodeRangeProperty {
2077                        container: container,
2078                        target_nodes: target_nodes.ok_or(::serde::de::Error::missing_field("TargetNodes"))?,
2079                    })
2080                }
2081            }
2082
2083            d.deserialize_map(Visitor)
2084        }
2085    }
2086
2087    /// The [`AWS::Batch::JobDefinition.ResourceRequirement`](http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-batch-jobdefinition-resourcerequirement.html) property type.
2088    #[derive(Debug, Default)]
2089    pub struct ResourceRequirement {
2090        /// Property [`Type`](http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-batch-jobdefinition-resourcerequirement.html#cfn-batch-jobdefinition-resourcerequirement-type).
2091        ///
2092        /// Update type: _Mutable_.
2093        /// AWS CloudFormation doesn't replace the resource when you change this property.
2094        pub r#type: Option<::Value<String>>,
2095        /// Property [`Value`](http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-batch-jobdefinition-resourcerequirement.html#cfn-batch-jobdefinition-resourcerequirement-value).
2096        ///
2097        /// Update type: _Mutable_.
2098        /// AWS CloudFormation doesn't replace the resource when you change this property.
2099        pub value: Option<::Value<String>>,
2100    }
2101
2102    impl ::codec::SerializeValue for ResourceRequirement {
2103        fn serialize<S: ::serde::Serializer>(&self, s: S) -> Result<S::Ok, S::Error> {
2104            let mut map = ::serde::Serializer::serialize_map(s, None)?;
2105            if let Some(ref r#type) = self.r#type {
2106                ::serde::ser::SerializeMap::serialize_entry(&mut map, "Type", r#type)?;
2107            }
2108            if let Some(ref value) = self.value {
2109                ::serde::ser::SerializeMap::serialize_entry(&mut map, "Value", value)?;
2110            }
2111            ::serde::ser::SerializeMap::end(map)
2112        }
2113    }
2114
2115    impl ::codec::DeserializeValue for ResourceRequirement {
2116        fn deserialize<'de, D: ::serde::Deserializer<'de>>(d: D) -> Result<ResourceRequirement, D::Error> {
2117            struct Visitor;
2118
2119            impl<'de> ::serde::de::Visitor<'de> for Visitor {
2120                type Value = ResourceRequirement;
2121
2122                fn expecting(&self, f: &mut ::std::fmt::Formatter) -> ::std::fmt::Result {
2123                    write!(f, "a struct of type ResourceRequirement")
2124                }
2125
2126                fn visit_map<A: ::serde::de::MapAccess<'de>>(self, mut map: A) -> Result<Self::Value, A::Error> {
2127                    let mut r#type: Option<::Value<String>> = None;
2128                    let mut value: Option<::Value<String>> = None;
2129
2130                    while let Some(__cfn_key) = ::serde::de::MapAccess::next_key::<String>(&mut map)? {
2131                        match __cfn_key.as_ref() {
2132                            "Type" => {
2133                                r#type = ::serde::de::MapAccess::next_value(&mut map)?;
2134                            }
2135                            "Value" => {
2136                                value = ::serde::de::MapAccess::next_value(&mut map)?;
2137                            }
2138                            _ => {}
2139                        }
2140                    }
2141
2142                    Ok(ResourceRequirement {
2143                        r#type: r#type,
2144                        value: value,
2145                    })
2146                }
2147            }
2148
2149            d.deserialize_map(Visitor)
2150        }
2151    }
2152
2153    /// The [`AWS::Batch::JobDefinition.RetryStrategy`](http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-batch-jobdefinition-retrystrategy.html) property type.
2154    #[derive(Debug, Default)]
2155    pub struct RetryStrategy {
2156        /// Property [`Attempts`](http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-batch-jobdefinition-retrystrategy.html#cfn-batch-jobdefinition-retrystrategy-attempts).
2157        ///
2158        /// Update type: _Mutable_.
2159        /// AWS CloudFormation doesn't replace the resource when you change this property.
2160        pub attempts: Option<::Value<u32>>,
2161        /// Property [`EvaluateOnExit`](http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-batch-jobdefinition-retrystrategy.html#cfn-batch-jobdefinition-retrystrategy-evaluateonexit).
2162        ///
2163        /// Update type: _Mutable_.
2164        /// AWS CloudFormation doesn't replace the resource when you change this property.
2165        pub evaluate_on_exit: Option<::ValueList<EvaluateOnExit>>,
2166    }
2167
2168    impl ::codec::SerializeValue for RetryStrategy {
2169        fn serialize<S: ::serde::Serializer>(&self, s: S) -> Result<S::Ok, S::Error> {
2170            let mut map = ::serde::Serializer::serialize_map(s, None)?;
2171            if let Some(ref attempts) = self.attempts {
2172                ::serde::ser::SerializeMap::serialize_entry(&mut map, "Attempts", attempts)?;
2173            }
2174            if let Some(ref evaluate_on_exit) = self.evaluate_on_exit {
2175                ::serde::ser::SerializeMap::serialize_entry(&mut map, "EvaluateOnExit", evaluate_on_exit)?;
2176            }
2177            ::serde::ser::SerializeMap::end(map)
2178        }
2179    }
2180
2181    impl ::codec::DeserializeValue for RetryStrategy {
2182        fn deserialize<'de, D: ::serde::Deserializer<'de>>(d: D) -> Result<RetryStrategy, D::Error> {
2183            struct Visitor;
2184
2185            impl<'de> ::serde::de::Visitor<'de> for Visitor {
2186                type Value = RetryStrategy;
2187
2188                fn expecting(&self, f: &mut ::std::fmt::Formatter) -> ::std::fmt::Result {
2189                    write!(f, "a struct of type RetryStrategy")
2190                }
2191
2192                fn visit_map<A: ::serde::de::MapAccess<'de>>(self, mut map: A) -> Result<Self::Value, A::Error> {
2193                    let mut attempts: Option<::Value<u32>> = None;
2194                    let mut evaluate_on_exit: Option<::ValueList<EvaluateOnExit>> = None;
2195
2196                    while let Some(__cfn_key) = ::serde::de::MapAccess::next_key::<String>(&mut map)? {
2197                        match __cfn_key.as_ref() {
2198                            "Attempts" => {
2199                                attempts = ::serde::de::MapAccess::next_value(&mut map)?;
2200                            }
2201                            "EvaluateOnExit" => {
2202                                evaluate_on_exit = ::serde::de::MapAccess::next_value(&mut map)?;
2203                            }
2204                            _ => {}
2205                        }
2206                    }
2207
2208                    Ok(RetryStrategy {
2209                        attempts: attempts,
2210                        evaluate_on_exit: evaluate_on_exit,
2211                    })
2212                }
2213            }
2214
2215            d.deserialize_map(Visitor)
2216        }
2217    }
2218
2219    /// The [`AWS::Batch::JobDefinition.Secret`](http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-batch-jobdefinition-secret.html) property type.
2220    #[derive(Debug, Default)]
2221    pub struct Secret {
2222        /// Property [`Name`](http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-batch-jobdefinition-secret.html#cfn-batch-jobdefinition-secret-name).
2223        ///
2224        /// Update type: _Mutable_.
2225        /// AWS CloudFormation doesn't replace the resource when you change this property.
2226        pub name: ::Value<String>,
2227        /// Property [`ValueFrom`](http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-batch-jobdefinition-secret.html#cfn-batch-jobdefinition-secret-valuefrom).
2228        ///
2229        /// Update type: _Mutable_.
2230        /// AWS CloudFormation doesn't replace the resource when you change this property.
2231        pub value_from: ::Value<String>,
2232    }
2233
2234    impl ::codec::SerializeValue for Secret {
2235        fn serialize<S: ::serde::Serializer>(&self, s: S) -> Result<S::Ok, S::Error> {
2236            let mut map = ::serde::Serializer::serialize_map(s, None)?;
2237            ::serde::ser::SerializeMap::serialize_entry(&mut map, "Name", &self.name)?;
2238            ::serde::ser::SerializeMap::serialize_entry(&mut map, "ValueFrom", &self.value_from)?;
2239            ::serde::ser::SerializeMap::end(map)
2240        }
2241    }
2242
2243    impl ::codec::DeserializeValue for Secret {
2244        fn deserialize<'de, D: ::serde::Deserializer<'de>>(d: D) -> Result<Secret, D::Error> {
2245            struct Visitor;
2246
2247            impl<'de> ::serde::de::Visitor<'de> for Visitor {
2248                type Value = Secret;
2249
2250                fn expecting(&self, f: &mut ::std::fmt::Formatter) -> ::std::fmt::Result {
2251                    write!(f, "a struct of type Secret")
2252                }
2253
2254                fn visit_map<A: ::serde::de::MapAccess<'de>>(self, mut map: A) -> Result<Self::Value, A::Error> {
2255                    let mut name: Option<::Value<String>> = None;
2256                    let mut value_from: Option<::Value<String>> = None;
2257
2258                    while let Some(__cfn_key) = ::serde::de::MapAccess::next_key::<String>(&mut map)? {
2259                        match __cfn_key.as_ref() {
2260                            "Name" => {
2261                                name = ::serde::de::MapAccess::next_value(&mut map)?;
2262                            }
2263                            "ValueFrom" => {
2264                                value_from = ::serde::de::MapAccess::next_value(&mut map)?;
2265                            }
2266                            _ => {}
2267                        }
2268                    }
2269
2270                    Ok(Secret {
2271                        name: name.ok_or(::serde::de::Error::missing_field("Name"))?,
2272                        value_from: value_from.ok_or(::serde::de::Error::missing_field("ValueFrom"))?,
2273                    })
2274                }
2275            }
2276
2277            d.deserialize_map(Visitor)
2278        }
2279    }
2280
2281    /// The [`AWS::Batch::JobDefinition.Timeout`](http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-batch-jobdefinition-timeout.html) property type.
2282    #[derive(Debug, Default)]
2283    pub struct Timeout {
2284        /// Property [`AttemptDurationSeconds`](http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-batch-jobdefinition-timeout.html#cfn-batch-jobdefinition-timeout-attemptdurationseconds).
2285        ///
2286        /// Update type: _Mutable_.
2287        /// AWS CloudFormation doesn't replace the resource when you change this property.
2288        pub attempt_duration_seconds: Option<::Value<u32>>,
2289    }
2290
2291    impl ::codec::SerializeValue for Timeout {
2292        fn serialize<S: ::serde::Serializer>(&self, s: S) -> Result<S::Ok, S::Error> {
2293            let mut map = ::serde::Serializer::serialize_map(s, None)?;
2294            if let Some(ref attempt_duration_seconds) = self.attempt_duration_seconds {
2295                ::serde::ser::SerializeMap::serialize_entry(&mut map, "AttemptDurationSeconds", attempt_duration_seconds)?;
2296            }
2297            ::serde::ser::SerializeMap::end(map)
2298        }
2299    }
2300
2301    impl ::codec::DeserializeValue for Timeout {
2302        fn deserialize<'de, D: ::serde::Deserializer<'de>>(d: D) -> Result<Timeout, D::Error> {
2303            struct Visitor;
2304
2305            impl<'de> ::serde::de::Visitor<'de> for Visitor {
2306                type Value = Timeout;
2307
2308                fn expecting(&self, f: &mut ::std::fmt::Formatter) -> ::std::fmt::Result {
2309                    write!(f, "a struct of type Timeout")
2310                }
2311
2312                fn visit_map<A: ::serde::de::MapAccess<'de>>(self, mut map: A) -> Result<Self::Value, A::Error> {
2313                    let mut attempt_duration_seconds: Option<::Value<u32>> = None;
2314
2315                    while let Some(__cfn_key) = ::serde::de::MapAccess::next_key::<String>(&mut map)? {
2316                        match __cfn_key.as_ref() {
2317                            "AttemptDurationSeconds" => {
2318                                attempt_duration_seconds = ::serde::de::MapAccess::next_value(&mut map)?;
2319                            }
2320                            _ => {}
2321                        }
2322                    }
2323
2324                    Ok(Timeout {
2325                        attempt_duration_seconds: attempt_duration_seconds,
2326                    })
2327                }
2328            }
2329
2330            d.deserialize_map(Visitor)
2331        }
2332    }
2333
2334    /// The [`AWS::Batch::JobDefinition.Tmpfs`](http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-batch-jobdefinition-tmpfs.html) property type.
2335    #[derive(Debug, Default)]
2336    pub struct Tmpfs {
2337        /// Property [`ContainerPath`](http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-batch-jobdefinition-tmpfs.html#cfn-batch-jobdefinition-tmpfs-containerpath).
2338        ///
2339        /// Update type: _Mutable_.
2340        /// AWS CloudFormation doesn't replace the resource when you change this property.
2341        pub container_path: ::Value<String>,
2342        /// Property [`MountOptions`](http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-batch-jobdefinition-tmpfs.html#cfn-batch-jobdefinition-tmpfs-mountoptions).
2343        ///
2344        /// Update type: _Mutable_.
2345        /// AWS CloudFormation doesn't replace the resource when you change this property.
2346        pub mount_options: Option<::ValueList<String>>,
2347        /// Property [`Size`](http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-batch-jobdefinition-tmpfs.html#cfn-batch-jobdefinition-tmpfs-size).
2348        ///
2349        /// Update type: _Mutable_.
2350        /// AWS CloudFormation doesn't replace the resource when you change this property.
2351        pub size: ::Value<u32>,
2352    }
2353
2354    impl ::codec::SerializeValue for Tmpfs {
2355        fn serialize<S: ::serde::Serializer>(&self, s: S) -> Result<S::Ok, S::Error> {
2356            let mut map = ::serde::Serializer::serialize_map(s, None)?;
2357            ::serde::ser::SerializeMap::serialize_entry(&mut map, "ContainerPath", &self.container_path)?;
2358            if let Some(ref mount_options) = self.mount_options {
2359                ::serde::ser::SerializeMap::serialize_entry(&mut map, "MountOptions", mount_options)?;
2360            }
2361            ::serde::ser::SerializeMap::serialize_entry(&mut map, "Size", &self.size)?;
2362            ::serde::ser::SerializeMap::end(map)
2363        }
2364    }
2365
2366    impl ::codec::DeserializeValue for Tmpfs {
2367        fn deserialize<'de, D: ::serde::Deserializer<'de>>(d: D) -> Result<Tmpfs, D::Error> {
2368            struct Visitor;
2369
2370            impl<'de> ::serde::de::Visitor<'de> for Visitor {
2371                type Value = Tmpfs;
2372
2373                fn expecting(&self, f: &mut ::std::fmt::Formatter) -> ::std::fmt::Result {
2374                    write!(f, "a struct of type Tmpfs")
2375                }
2376
2377                fn visit_map<A: ::serde::de::MapAccess<'de>>(self, mut map: A) -> Result<Self::Value, A::Error> {
2378                    let mut container_path: Option<::Value<String>> = None;
2379                    let mut mount_options: Option<::ValueList<String>> = None;
2380                    let mut size: Option<::Value<u32>> = None;
2381
2382                    while let Some(__cfn_key) = ::serde::de::MapAccess::next_key::<String>(&mut map)? {
2383                        match __cfn_key.as_ref() {
2384                            "ContainerPath" => {
2385                                container_path = ::serde::de::MapAccess::next_value(&mut map)?;
2386                            }
2387                            "MountOptions" => {
2388                                mount_options = ::serde::de::MapAccess::next_value(&mut map)?;
2389                            }
2390                            "Size" => {
2391                                size = ::serde::de::MapAccess::next_value(&mut map)?;
2392                            }
2393                            _ => {}
2394                        }
2395                    }
2396
2397                    Ok(Tmpfs {
2398                        container_path: container_path.ok_or(::serde::de::Error::missing_field("ContainerPath"))?,
2399                        mount_options: mount_options,
2400                        size: size.ok_or(::serde::de::Error::missing_field("Size"))?,
2401                    })
2402                }
2403            }
2404
2405            d.deserialize_map(Visitor)
2406        }
2407    }
2408
2409    /// The [`AWS::Batch::JobDefinition.Ulimit`](http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-batch-jobdefinition-ulimit.html) property type.
2410    #[derive(Debug, Default)]
2411    pub struct Ulimit {
2412        /// Property [`HardLimit`](http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-batch-jobdefinition-ulimit.html#cfn-batch-jobdefinition-ulimit-hardlimit).
2413        ///
2414        /// Update type: _Mutable_.
2415        /// AWS CloudFormation doesn't replace the resource when you change this property.
2416        pub hard_limit: ::Value<u32>,
2417        /// Property [`Name`](http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-batch-jobdefinition-ulimit.html#cfn-batch-jobdefinition-ulimit-name).
2418        ///
2419        /// Update type: _Mutable_.
2420        /// AWS CloudFormation doesn't replace the resource when you change this property.
2421        pub name: ::Value<String>,
2422        /// Property [`SoftLimit`](http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-batch-jobdefinition-ulimit.html#cfn-batch-jobdefinition-ulimit-softlimit).
2423        ///
2424        /// Update type: _Mutable_.
2425        /// AWS CloudFormation doesn't replace the resource when you change this property.
2426        pub soft_limit: ::Value<u32>,
2427    }
2428
2429    impl ::codec::SerializeValue for Ulimit {
2430        fn serialize<S: ::serde::Serializer>(&self, s: S) -> Result<S::Ok, S::Error> {
2431            let mut map = ::serde::Serializer::serialize_map(s, None)?;
2432            ::serde::ser::SerializeMap::serialize_entry(&mut map, "HardLimit", &self.hard_limit)?;
2433            ::serde::ser::SerializeMap::serialize_entry(&mut map, "Name", &self.name)?;
2434            ::serde::ser::SerializeMap::serialize_entry(&mut map, "SoftLimit", &self.soft_limit)?;
2435            ::serde::ser::SerializeMap::end(map)
2436        }
2437    }
2438
2439    impl ::codec::DeserializeValue for Ulimit {
2440        fn deserialize<'de, D: ::serde::Deserializer<'de>>(d: D) -> Result<Ulimit, D::Error> {
2441            struct Visitor;
2442
2443            impl<'de> ::serde::de::Visitor<'de> for Visitor {
2444                type Value = Ulimit;
2445
2446                fn expecting(&self, f: &mut ::std::fmt::Formatter) -> ::std::fmt::Result {
2447                    write!(f, "a struct of type Ulimit")
2448                }
2449
2450                fn visit_map<A: ::serde::de::MapAccess<'de>>(self, mut map: A) -> Result<Self::Value, A::Error> {
2451                    let mut hard_limit: Option<::Value<u32>> = None;
2452                    let mut name: Option<::Value<String>> = None;
2453                    let mut soft_limit: Option<::Value<u32>> = None;
2454
2455                    while let Some(__cfn_key) = ::serde::de::MapAccess::next_key::<String>(&mut map)? {
2456                        match __cfn_key.as_ref() {
2457                            "HardLimit" => {
2458                                hard_limit = ::serde::de::MapAccess::next_value(&mut map)?;
2459                            }
2460                            "Name" => {
2461                                name = ::serde::de::MapAccess::next_value(&mut map)?;
2462                            }
2463                            "SoftLimit" => {
2464                                soft_limit = ::serde::de::MapAccess::next_value(&mut map)?;
2465                            }
2466                            _ => {}
2467                        }
2468                    }
2469
2470                    Ok(Ulimit {
2471                        hard_limit: hard_limit.ok_or(::serde::de::Error::missing_field("HardLimit"))?,
2472                        name: name.ok_or(::serde::de::Error::missing_field("Name"))?,
2473                        soft_limit: soft_limit.ok_or(::serde::de::Error::missing_field("SoftLimit"))?,
2474                    })
2475                }
2476            }
2477
2478            d.deserialize_map(Visitor)
2479        }
2480    }
2481
2482    /// The [`AWS::Batch::JobDefinition.Volumes`](http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-batch-jobdefinition-volumes.html) property type.
2483    #[derive(Debug, Default)]
2484    pub struct Volumes {
2485        /// Property [`EfsVolumeConfiguration`](http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-batch-jobdefinition-volumes.html#cfn-batch-jobdefinition-volumes-efsvolumeconfiguration).
2486        ///
2487        /// Update type: _Mutable_.
2488        /// AWS CloudFormation doesn't replace the resource when you change this property.
2489        pub efs_volume_configuration: Option<::Value<EfsVolumeConfiguration>>,
2490        /// Property [`Host`](http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-batch-jobdefinition-volumes.html#cfn-batch-jobdefinition-volumes-host).
2491        ///
2492        /// Update type: _Mutable_.
2493        /// AWS CloudFormation doesn't replace the resource when you change this property.
2494        pub host: Option<::Value<VolumesHost>>,
2495        /// Property [`Name`](http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-batch-jobdefinition-volumes.html#cfn-batch-jobdefinition-volumes-name).
2496        ///
2497        /// Update type: _Mutable_.
2498        /// AWS CloudFormation doesn't replace the resource when you change this property.
2499        pub name: Option<::Value<String>>,
2500    }
2501
2502    impl ::codec::SerializeValue for Volumes {
2503        fn serialize<S: ::serde::Serializer>(&self, s: S) -> Result<S::Ok, S::Error> {
2504            let mut map = ::serde::Serializer::serialize_map(s, None)?;
2505            if let Some(ref efs_volume_configuration) = self.efs_volume_configuration {
2506                ::serde::ser::SerializeMap::serialize_entry(&mut map, "EfsVolumeConfiguration", efs_volume_configuration)?;
2507            }
2508            if let Some(ref host) = self.host {
2509                ::serde::ser::SerializeMap::serialize_entry(&mut map, "Host", host)?;
2510            }
2511            if let Some(ref name) = self.name {
2512                ::serde::ser::SerializeMap::serialize_entry(&mut map, "Name", name)?;
2513            }
2514            ::serde::ser::SerializeMap::end(map)
2515        }
2516    }
2517
2518    impl ::codec::DeserializeValue for Volumes {
2519        fn deserialize<'de, D: ::serde::Deserializer<'de>>(d: D) -> Result<Volumes, D::Error> {
2520            struct Visitor;
2521
2522            impl<'de> ::serde::de::Visitor<'de> for Visitor {
2523                type Value = Volumes;
2524
2525                fn expecting(&self, f: &mut ::std::fmt::Formatter) -> ::std::fmt::Result {
2526                    write!(f, "a struct of type Volumes")
2527                }
2528
2529                fn visit_map<A: ::serde::de::MapAccess<'de>>(self, mut map: A) -> Result<Self::Value, A::Error> {
2530                    let mut efs_volume_configuration: Option<::Value<EfsVolumeConfiguration>> = None;
2531                    let mut host: Option<::Value<VolumesHost>> = None;
2532                    let mut name: Option<::Value<String>> = None;
2533
2534                    while let Some(__cfn_key) = ::serde::de::MapAccess::next_key::<String>(&mut map)? {
2535                        match __cfn_key.as_ref() {
2536                            "EfsVolumeConfiguration" => {
2537                                efs_volume_configuration = ::serde::de::MapAccess::next_value(&mut map)?;
2538                            }
2539                            "Host" => {
2540                                host = ::serde::de::MapAccess::next_value(&mut map)?;
2541                            }
2542                            "Name" => {
2543                                name = ::serde::de::MapAccess::next_value(&mut map)?;
2544                            }
2545                            _ => {}
2546                        }
2547                    }
2548
2549                    Ok(Volumes {
2550                        efs_volume_configuration: efs_volume_configuration,
2551                        host: host,
2552                        name: name,
2553                    })
2554                }
2555            }
2556
2557            d.deserialize_map(Visitor)
2558        }
2559    }
2560
2561    /// The [`AWS::Batch::JobDefinition.VolumesHost`](http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-batch-jobdefinition-volumeshost.html) property type.
2562    #[derive(Debug, Default)]
2563    pub struct VolumesHost {
2564        /// Property [`SourcePath`](http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-batch-jobdefinition-volumeshost.html#cfn-batch-jobdefinition-volumeshost-sourcepath).
2565        ///
2566        /// Update type: _Mutable_.
2567        /// AWS CloudFormation doesn't replace the resource when you change this property.
2568        pub source_path: Option<::Value<String>>,
2569    }
2570
2571    impl ::codec::SerializeValue for VolumesHost {
2572        fn serialize<S: ::serde::Serializer>(&self, s: S) -> Result<S::Ok, S::Error> {
2573            let mut map = ::serde::Serializer::serialize_map(s, None)?;
2574            if let Some(ref source_path) = self.source_path {
2575                ::serde::ser::SerializeMap::serialize_entry(&mut map, "SourcePath", source_path)?;
2576            }
2577            ::serde::ser::SerializeMap::end(map)
2578        }
2579    }
2580
2581    impl ::codec::DeserializeValue for VolumesHost {
2582        fn deserialize<'de, D: ::serde::Deserializer<'de>>(d: D) -> Result<VolumesHost, D::Error> {
2583            struct Visitor;
2584
2585            impl<'de> ::serde::de::Visitor<'de> for Visitor {
2586                type Value = VolumesHost;
2587
2588                fn expecting(&self, f: &mut ::std::fmt::Formatter) -> ::std::fmt::Result {
2589                    write!(f, "a struct of type VolumesHost")
2590                }
2591
2592                fn visit_map<A: ::serde::de::MapAccess<'de>>(self, mut map: A) -> Result<Self::Value, A::Error> {
2593                    let mut source_path: Option<::Value<String>> = None;
2594
2595                    while let Some(__cfn_key) = ::serde::de::MapAccess::next_key::<String>(&mut map)? {
2596                        match __cfn_key.as_ref() {
2597                            "SourcePath" => {
2598                                source_path = ::serde::de::MapAccess::next_value(&mut map)?;
2599                            }
2600                            _ => {}
2601                        }
2602                    }
2603
2604                    Ok(VolumesHost {
2605                        source_path: source_path,
2606                    })
2607                }
2608            }
2609
2610            d.deserialize_map(Visitor)
2611        }
2612    }
2613}
2614
2615pub mod job_queue {
2616    //! Property types for the `JobQueue` resource.
2617
2618    /// The [`AWS::Batch::JobQueue.ComputeEnvironmentOrder`](http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-batch-jobqueue-computeenvironmentorder.html) property type.
2619    #[derive(Debug, Default)]
2620    pub struct ComputeEnvironmentOrder {
2621        /// Property [`ComputeEnvironment`](http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-batch-jobqueue-computeenvironmentorder.html#cfn-batch-jobqueue-computeenvironmentorder-computeenvironment).
2622        ///
2623        /// Update type: _Mutable_.
2624        /// AWS CloudFormation doesn't replace the resource when you change this property.
2625        pub compute_environment: ::Value<String>,
2626        /// Property [`Order`](http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-batch-jobqueue-computeenvironmentorder.html#cfn-batch-jobqueue-computeenvironmentorder-order).
2627        ///
2628        /// Update type: _Mutable_.
2629        /// AWS CloudFormation doesn't replace the resource when you change this property.
2630        pub order: ::Value<u32>,
2631    }
2632
2633    impl ::codec::SerializeValue for ComputeEnvironmentOrder {
2634        fn serialize<S: ::serde::Serializer>(&self, s: S) -> Result<S::Ok, S::Error> {
2635            let mut map = ::serde::Serializer::serialize_map(s, None)?;
2636            ::serde::ser::SerializeMap::serialize_entry(&mut map, "ComputeEnvironment", &self.compute_environment)?;
2637            ::serde::ser::SerializeMap::serialize_entry(&mut map, "Order", &self.order)?;
2638            ::serde::ser::SerializeMap::end(map)
2639        }
2640    }
2641
2642    impl ::codec::DeserializeValue for ComputeEnvironmentOrder {
2643        fn deserialize<'de, D: ::serde::Deserializer<'de>>(d: D) -> Result<ComputeEnvironmentOrder, D::Error> {
2644            struct Visitor;
2645
2646            impl<'de> ::serde::de::Visitor<'de> for Visitor {
2647                type Value = ComputeEnvironmentOrder;
2648
2649                fn expecting(&self, f: &mut ::std::fmt::Formatter) -> ::std::fmt::Result {
2650                    write!(f, "a struct of type ComputeEnvironmentOrder")
2651                }
2652
2653                fn visit_map<A: ::serde::de::MapAccess<'de>>(self, mut map: A) -> Result<Self::Value, A::Error> {
2654                    let mut compute_environment: Option<::Value<String>> = None;
2655                    let mut order: Option<::Value<u32>> = None;
2656
2657                    while let Some(__cfn_key) = ::serde::de::MapAccess::next_key::<String>(&mut map)? {
2658                        match __cfn_key.as_ref() {
2659                            "ComputeEnvironment" => {
2660                                compute_environment = ::serde::de::MapAccess::next_value(&mut map)?;
2661                            }
2662                            "Order" => {
2663                                order = ::serde::de::MapAccess::next_value(&mut map)?;
2664                            }
2665                            _ => {}
2666                        }
2667                    }
2668
2669                    Ok(ComputeEnvironmentOrder {
2670                        compute_environment: compute_environment.ok_or(::serde::de::Error::missing_field("ComputeEnvironment"))?,
2671                        order: order.ok_or(::serde::de::Error::missing_field("Order"))?,
2672                    })
2673                }
2674            }
2675
2676            d.deserialize_map(Visitor)
2677        }
2678    }
2679}