aws_sdk_ec2/protocol_serde/
shape_access_scope_path.rs

1// Code generated by software.amazon.smithy.rust.codegen.smithy-rs. DO NOT EDIT.
2#[allow(clippy::needless_question_mark)]
3pub fn de_access_scope_path(
4    decoder: &mut ::aws_smithy_xml::decode::ScopedDecoder,
5) -> ::std::result::Result<crate::types::AccessScopePath, ::aws_smithy_xml::decode::XmlDecodeError> {
6    #[allow(unused_mut)]
7    let mut builder = crate::types::AccessScopePath::builder();
8    while let Some(mut tag) = decoder.next_tag() {
9        match tag.start_el() {
10            s if s.matches("source") /* Source com.amazonaws.ec2#AccessScopePath$Source */ =>  {
11                let var_1 =
12                    Some(
13                        crate::protocol_serde::shape_path_statement::de_path_statement(&mut tag)
14                        ?
15                    )
16                ;
17                builder = builder.set_source(var_1);
18            }
19            ,
20            s if s.matches("destination") /* Destination com.amazonaws.ec2#AccessScopePath$Destination */ =>  {
21                let var_2 =
22                    Some(
23                        crate::protocol_serde::shape_path_statement::de_path_statement(&mut tag)
24                        ?
25                    )
26                ;
27                builder = builder.set_destination(var_2);
28            }
29            ,
30            s if s.matches("throughResourceSet") /* ThroughResources com.amazonaws.ec2#AccessScopePath$ThroughResources */ =>  {
31                let var_3 =
32                    Some(
33                        crate::protocol_serde::shape_through_resources_statement_list::de_through_resources_statement_list(&mut tag)
34                        ?
35                    )
36                ;
37                builder = builder.set_through_resources(var_3);
38            }
39            ,
40            _ => {}
41        }
42    }
43    Ok(builder.build())
44}