aws_sdk_s3/protocol_serde/
shape_storage_class_analysis.rs
1#[allow(clippy::needless_question_mark)]
3pub fn de_storage_class_analysis(
4 decoder: &mut ::aws_smithy_xml::decode::ScopedDecoder,
5) -> ::std::result::Result<crate::types::StorageClassAnalysis, ::aws_smithy_xml::decode::XmlDecodeError> {
6 #[allow(unused_mut)]
7 let mut builder = crate::types::StorageClassAnalysis::builder();
8 while let Some(mut tag) = decoder.next_tag() {
9 match tag.start_el() {
10 s if s.matches("DataExport") => {
11 let var_1 =
12 Some(
13 crate::protocol_serde::shape_storage_class_analysis_data_export::de_storage_class_analysis_data_export(&mut tag)
14 ?
15 )
16 ;
17 builder = builder.set_data_export(var_1);
18 }
19 ,
20 _ => {}
21 }
22 }
23 Ok(builder.build())
24}
25
26pub fn ser_storage_class_analysis(
27 input: &crate::types::StorageClassAnalysis,
28 writer: ::aws_smithy_xml::encode::ElWriter,
29) -> ::std::result::Result<(), ::aws_smithy_types::error::operation::SerializationError> {
30 #[allow(unused_mut)]
31 let mut scope = writer.finish();
32 if let Some(var_2) = &input.data_export {
33 let inner_writer = scope.start_el("DataExport");
34 crate::protocol_serde::shape_storage_class_analysis_data_export::ser_storage_class_analysis_data_export(var_2, inner_writer)?
35 }
36 scope.finish();
37 Ok(())
38}