pub fn parse_http_generic_error(
response: &http::Response<bytes::Bytes>,
) -> Result<aws_smithy_types::Error, aws_smithy_xml::decode::XmlDecodeError> {
crate::rest_xml_wrapped_errors::parse_generic_error(response.body().as_ref())
}
#[allow(unused_mut)]
pub fn deser_structure_crate_error_authorization_error_exception_xml_err(
inp: &[u8],
mut builder: crate::error::authorization_error_exception::Builder,
) -> Result<
crate::error::authorization_error_exception::Builder,
aws_smithy_xml::decode::XmlDecodeError,
> {
if inp.is_empty() {
return Ok(builder);
}
let mut document = aws_smithy_xml::decode::Document::try_from(inp)?;
#[allow(unused_mut)]
let mut error_decoder = crate::rest_xml_wrapped_errors::error_scope(&mut document)?;
while let Some(mut tag) = error_decoder.next_tag() {
match tag.start_el() {
s if s.matches("message") => {
let var_1 =
Some(
Result::<std::string::String, aws_smithy_xml::decode::XmlDecodeError>::Ok(
aws_smithy_xml::decode::try_data(&mut tag)?.as_ref()
.into()
)
?
)
;
builder = builder.set_message(var_1);
}
,
_ => {}
}
}
Ok(builder)
}
#[allow(unused_mut)]
pub fn deser_structure_crate_error_internal_error_exception_xml_err(
inp: &[u8],
mut builder: crate::error::internal_error_exception::Builder,
) -> Result<crate::error::internal_error_exception::Builder, aws_smithy_xml::decode::XmlDecodeError>
{
if inp.is_empty() {
return Ok(builder);
}
let mut document = aws_smithy_xml::decode::Document::try_from(inp)?;
#[allow(unused_mut)]
let mut error_decoder = crate::rest_xml_wrapped_errors::error_scope(&mut document)?;
while let Some(mut tag) = error_decoder.next_tag() {
match tag.start_el() {
s if s.matches("message") => {
let var_2 =
Some(
Result::<std::string::String, aws_smithy_xml::decode::XmlDecodeError>::Ok(
aws_smithy_xml::decode::try_data(&mut tag)?.as_ref()
.into()
)
?
)
;
builder = builder.set_message(var_2);
}
,
_ => {}
}
}
Ok(builder)
}
#[allow(unused_mut)]
pub fn deser_structure_crate_error_invalid_parameter_exception_xml_err(
inp: &[u8],
mut builder: crate::error::invalid_parameter_exception::Builder,
) -> Result<
crate::error::invalid_parameter_exception::Builder,
aws_smithy_xml::decode::XmlDecodeError,
> {
if inp.is_empty() {
return Ok(builder);
}
let mut document = aws_smithy_xml::decode::Document::try_from(inp)?;
#[allow(unused_mut)]
let mut error_decoder = crate::rest_xml_wrapped_errors::error_scope(&mut document)?;
while let Some(mut tag) = error_decoder.next_tag() {
match tag.start_el() {
s if s.matches("message") => {
let var_3 =
Some(
Result::<std::string::String, aws_smithy_xml::decode::XmlDecodeError>::Ok(
aws_smithy_xml::decode::try_data(&mut tag)?.as_ref()
.into()
)
?
)
;
builder = builder.set_message(var_3);
}
,
_ => {}
}
}
Ok(builder)
}
#[allow(unused_mut)]
pub fn deser_structure_crate_error_not_found_exception_xml_err(
inp: &[u8],
mut builder: crate::error::not_found_exception::Builder,
) -> Result<crate::error::not_found_exception::Builder, aws_smithy_xml::decode::XmlDecodeError> {
if inp.is_empty() {
return Ok(builder);
}
let mut document = aws_smithy_xml::decode::Document::try_from(inp)?;
#[allow(unused_mut)]
let mut error_decoder = crate::rest_xml_wrapped_errors::error_scope(&mut document)?;
while let Some(mut tag) = error_decoder.next_tag() {
match tag.start_el() {
s if s.matches("message") => {
let var_4 =
Some(
Result::<std::string::String, aws_smithy_xml::decode::XmlDecodeError>::Ok(
aws_smithy_xml::decode::try_data(&mut tag)?.as_ref()
.into()
)
?
)
;
builder = builder.set_message(var_4);
}
,
_ => {}
}
}
Ok(builder)
}
#[allow(unused_mut)]
pub fn deser_structure_crate_error_throttled_exception_xml_err(
inp: &[u8],
mut builder: crate::error::throttled_exception::Builder,
) -> Result<crate::error::throttled_exception::Builder, aws_smithy_xml::decode::XmlDecodeError> {
if inp.is_empty() {
return Ok(builder);
}
let mut document = aws_smithy_xml::decode::Document::try_from(inp)?;
#[allow(unused_mut)]
let mut error_decoder = crate::rest_xml_wrapped_errors::error_scope(&mut document)?;
while let Some(mut tag) = error_decoder.next_tag() {
match tag.start_el() {
s if s.matches("message") => {
let var_5 =
Some(
Result::<std::string::String, aws_smithy_xml::decode::XmlDecodeError>::Ok(
aws_smithy_xml::decode::try_data(&mut tag)?.as_ref()
.into()
)
?
)
;
builder = builder.set_message(var_5);
}
,
_ => {}
}
}
Ok(builder)
}
#[allow(unused_mut)]
pub fn deser_operation_crate_operation_check_if_phone_number_is_opted_out(
inp: &[u8],
mut builder: crate::output::check_if_phone_number_is_opted_out_output::Builder,
) -> Result<
crate::output::check_if_phone_number_is_opted_out_output::Builder,
aws_smithy_xml::decode::XmlDecodeError,
> {
let mut doc = aws_smithy_xml::decode::Document::try_from(inp)?;
#[allow(unused_mut)]
let mut decoder = doc.root_element()?;
#[allow(unused_variables)]
let start_el = decoder.start_el();
if !(start_el.matches("CheckIfPhoneNumberIsOptedOutResponse")) {
return Err(aws_smithy_xml::decode::XmlDecodeError::custom(format!(
"invalid root, expected CheckIfPhoneNumberIsOptedOutResponse got {:?}",
start_el
)));
}
if let Some(mut result_tag) = decoder.next_tag() {
let start_el = result_tag.start_el();
if !(start_el.matches("CheckIfPhoneNumberIsOptedOutResult")) {
return Err(aws_smithy_xml::decode::XmlDecodeError::custom(format!(
"invalid result, expected CheckIfPhoneNumberIsOptedOutResult got {:?}",
start_el
)));
}
while let Some(mut tag) = result_tag.next_tag() {
match tag.start_el() {
s if s.matches("isOptedOut") => {
let var_6 =
Some(
{
<bool as aws_smithy_types::primitive::Parse>::parse_smithy_primitive(
aws_smithy_xml::decode::try_data(&mut tag)?.as_ref()
)
.map_err(|_|aws_smithy_xml::decode::XmlDecodeError::custom("expected (boolean: `com.amazonaws.sns#boolean`)"))
}
?
)
;
builder = builder.set_is_opted_out(var_6);
}
,
_ => {}
}
}
} else {
return Err(aws_smithy_xml::decode::XmlDecodeError::custom(
"expected CheckIfPhoneNumberIsOptedOutResult tag",
));
};
Ok(builder)
}
#[allow(unused_mut)]
pub fn deser_structure_crate_error_filter_policy_limit_exceeded_exception_xml_err(
inp: &[u8],
mut builder: crate::error::filter_policy_limit_exceeded_exception::Builder,
) -> Result<
crate::error::filter_policy_limit_exceeded_exception::Builder,
aws_smithy_xml::decode::XmlDecodeError,
> {
if inp.is_empty() {
return Ok(builder);
}
let mut document = aws_smithy_xml::decode::Document::try_from(inp)?;
#[allow(unused_mut)]
let mut error_decoder = crate::rest_xml_wrapped_errors::error_scope(&mut document)?;
while let Some(mut tag) = error_decoder.next_tag() {
match tag.start_el() {
s if s.matches("message") => {
let var_7 =
Some(
Result::<std::string::String, aws_smithy_xml::decode::XmlDecodeError>::Ok(
aws_smithy_xml::decode::try_data(&mut tag)?.as_ref()
.into()
)
?
)
;
builder = builder.set_message(var_7);
}
,
_ => {}
}
}
Ok(builder)
}
#[allow(unused_mut)]
pub fn deser_structure_crate_error_subscription_limit_exceeded_exception_xml_err(
inp: &[u8],
mut builder: crate::error::subscription_limit_exceeded_exception::Builder,
) -> Result<
crate::error::subscription_limit_exceeded_exception::Builder,
aws_smithy_xml::decode::XmlDecodeError,
> {
if inp.is_empty() {
return Ok(builder);
}
let mut document = aws_smithy_xml::decode::Document::try_from(inp)?;
#[allow(unused_mut)]
let mut error_decoder = crate::rest_xml_wrapped_errors::error_scope(&mut document)?;
while let Some(mut tag) = error_decoder.next_tag() {
match tag.start_el() {
s if s.matches("message") => {
let var_8 =
Some(
Result::<std::string::String, aws_smithy_xml::decode::XmlDecodeError>::Ok(
aws_smithy_xml::decode::try_data(&mut tag)?.as_ref()
.into()
)
?
)
;
builder = builder.set_message(var_8);
}
,
_ => {}
}
}
Ok(builder)
}
#[allow(unused_mut)]
pub fn deser_operation_crate_operation_confirm_subscription(
inp: &[u8],
mut builder: crate::output::confirm_subscription_output::Builder,
) -> Result<
crate::output::confirm_subscription_output::Builder,
aws_smithy_xml::decode::XmlDecodeError,
> {
let mut doc = aws_smithy_xml::decode::Document::try_from(inp)?;
#[allow(unused_mut)]
let mut decoder = doc.root_element()?;
#[allow(unused_variables)]
let start_el = decoder.start_el();
if !(start_el.matches("ConfirmSubscriptionResponse")) {
return Err(aws_smithy_xml::decode::XmlDecodeError::custom(format!(
"invalid root, expected ConfirmSubscriptionResponse got {:?}",
start_el
)));
}
if let Some(mut result_tag) = decoder.next_tag() {
let start_el = result_tag.start_el();
if !(start_el.matches("ConfirmSubscriptionResult")) {
return Err(aws_smithy_xml::decode::XmlDecodeError::custom(format!(
"invalid result, expected ConfirmSubscriptionResult got {:?}",
start_el
)));
}
while let Some(mut tag) = result_tag.next_tag() {
match tag.start_el() {
s if s.matches("SubscriptionArn") => {
let var_9 =
Some(
Result::<std::string::String, aws_smithy_xml::decode::XmlDecodeError>::Ok(
aws_smithy_xml::decode::try_data(&mut tag)?.as_ref()
.into()
)
?
)
;
builder = builder.set_subscription_arn(var_9);
}
,
_ => {}
}
}
} else {
return Err(aws_smithy_xml::decode::XmlDecodeError::custom(
"expected ConfirmSubscriptionResult tag",
));
};
Ok(builder)
}
#[allow(unused_mut)]
pub fn deser_operation_crate_operation_create_platform_application(
inp: &[u8],
mut builder: crate::output::create_platform_application_output::Builder,
) -> Result<
crate::output::create_platform_application_output::Builder,
aws_smithy_xml::decode::XmlDecodeError,
> {
let mut doc = aws_smithy_xml::decode::Document::try_from(inp)?;
#[allow(unused_mut)]
let mut decoder = doc.root_element()?;
#[allow(unused_variables)]
let start_el = decoder.start_el();
if !(start_el.matches("CreatePlatformApplicationResponse")) {
return Err(aws_smithy_xml::decode::XmlDecodeError::custom(format!(
"invalid root, expected CreatePlatformApplicationResponse got {:?}",
start_el
)));
}
if let Some(mut result_tag) = decoder.next_tag() {
let start_el = result_tag.start_el();
if !(start_el.matches("CreatePlatformApplicationResult")) {
return Err(aws_smithy_xml::decode::XmlDecodeError::custom(format!(
"invalid result, expected CreatePlatformApplicationResult got {:?}",
start_el
)));
}
while let Some(mut tag) = result_tag.next_tag() {
match tag.start_el() {
s if s.matches("PlatformApplicationArn") => {
let var_10 =
Some(
Result::<std::string::String, aws_smithy_xml::decode::XmlDecodeError>::Ok(
aws_smithy_xml::decode::try_data(&mut tag)?.as_ref()
.into()
)
?
)
;
builder = builder.set_platform_application_arn(var_10);
}
,
_ => {}
}
}
} else {
return Err(aws_smithy_xml::decode::XmlDecodeError::custom(
"expected CreatePlatformApplicationResult tag",
));
};
Ok(builder)
}
#[allow(unused_mut)]
pub fn deser_operation_crate_operation_create_platform_endpoint(
inp: &[u8],
mut builder: crate::output::create_platform_endpoint_output::Builder,
) -> Result<
crate::output::create_platform_endpoint_output::Builder,
aws_smithy_xml::decode::XmlDecodeError,
> {
let mut doc = aws_smithy_xml::decode::Document::try_from(inp)?;
#[allow(unused_mut)]
let mut decoder = doc.root_element()?;
#[allow(unused_variables)]
let start_el = decoder.start_el();
if !(start_el.matches("CreatePlatformEndpointResponse")) {
return Err(aws_smithy_xml::decode::XmlDecodeError::custom(format!(
"invalid root, expected CreatePlatformEndpointResponse got {:?}",
start_el
)));
}
if let Some(mut result_tag) = decoder.next_tag() {
let start_el = result_tag.start_el();
if !(start_el.matches("CreatePlatformEndpointResult")) {
return Err(aws_smithy_xml::decode::XmlDecodeError::custom(format!(
"invalid result, expected CreatePlatformEndpointResult got {:?}",
start_el
)));
}
while let Some(mut tag) = result_tag.next_tag() {
match tag.start_el() {
s if s.matches("EndpointArn") => {
let var_11 =
Some(
Result::<std::string::String, aws_smithy_xml::decode::XmlDecodeError>::Ok(
aws_smithy_xml::decode::try_data(&mut tag)?.as_ref()
.into()
)
?
)
;
builder = builder.set_endpoint_arn(var_11);
}
,
_ => {}
}
}
} else {
return Err(aws_smithy_xml::decode::XmlDecodeError::custom(
"expected CreatePlatformEndpointResult tag",
));
};
Ok(builder)
}
#[allow(unused_mut)]
pub fn deser_structure_crate_error_opted_out_exception_xml_err(
inp: &[u8],
mut builder: crate::error::opted_out_exception::Builder,
) -> Result<crate::error::opted_out_exception::Builder, aws_smithy_xml::decode::XmlDecodeError> {
if inp.is_empty() {
return Ok(builder);
}
let mut document = aws_smithy_xml::decode::Document::try_from(inp)?;
#[allow(unused_mut)]
let mut error_decoder = crate::rest_xml_wrapped_errors::error_scope(&mut document)?;
while let Some(mut tag) = error_decoder.next_tag() {
match tag.start_el() {
s if s.matches("message") => {
let var_12 =
Some(
Result::<std::string::String, aws_smithy_xml::decode::XmlDecodeError>::Ok(
aws_smithy_xml::decode::try_data(&mut tag)?.as_ref()
.into()
)
?
)
;
builder = builder.set_message(var_12);
}
,
_ => {}
}
}
Ok(builder)
}
#[allow(unused_mut)]
pub fn deser_structure_crate_error_user_error_exception_xml_err(
inp: &[u8],
mut builder: crate::error::user_error_exception::Builder,
) -> Result<crate::error::user_error_exception::Builder, aws_smithy_xml::decode::XmlDecodeError> {
if inp.is_empty() {
return Ok(builder);
}
let mut document = aws_smithy_xml::decode::Document::try_from(inp)?;
#[allow(unused_mut)]
let mut error_decoder = crate::rest_xml_wrapped_errors::error_scope(&mut document)?;
while let Some(mut tag) = error_decoder.next_tag() {
match tag.start_el() {
s if s.matches("message") => {
let var_13 =
Some(
Result::<std::string::String, aws_smithy_xml::decode::XmlDecodeError>::Ok(
aws_smithy_xml::decode::try_data(&mut tag)?.as_ref()
.into()
)
?
)
;
builder = builder.set_message(var_13);
}
,
_ => {}
}
}
Ok(builder)
}
#[allow(unused_mut)]
pub fn deser_structure_crate_error_concurrent_access_exception_xml_err(
inp: &[u8],
mut builder: crate::error::concurrent_access_exception::Builder,
) -> Result<
crate::error::concurrent_access_exception::Builder,
aws_smithy_xml::decode::XmlDecodeError,
> {
if inp.is_empty() {
return Ok(builder);
}
let mut document = aws_smithy_xml::decode::Document::try_from(inp)?;
#[allow(unused_mut)]
let mut error_decoder = crate::rest_xml_wrapped_errors::error_scope(&mut document)?;
while let Some(mut tag) = error_decoder.next_tag() {
match tag.start_el() {
s if s.matches("message") => {
let var_14 =
Some(
Result::<std::string::String, aws_smithy_xml::decode::XmlDecodeError>::Ok(
aws_smithy_xml::decode::try_data(&mut tag)?.as_ref()
.into()
)
?
)
;
builder = builder.set_message(var_14);
}
,
_ => {}
}
}
Ok(builder)
}
#[allow(unused_mut)]
pub fn deser_structure_crate_error_invalid_security_exception_xml_err(
inp: &[u8],
mut builder: crate::error::invalid_security_exception::Builder,
) -> Result<crate::error::invalid_security_exception::Builder, aws_smithy_xml::decode::XmlDecodeError>
{
if inp.is_empty() {
return Ok(builder);
}
let mut document = aws_smithy_xml::decode::Document::try_from(inp)?;
#[allow(unused_mut)]
let mut error_decoder = crate::rest_xml_wrapped_errors::error_scope(&mut document)?;
while let Some(mut tag) = error_decoder.next_tag() {
match tag.start_el() {
s if s.matches("message") => {
let var_15 =
Some(
Result::<std::string::String, aws_smithy_xml::decode::XmlDecodeError>::Ok(
aws_smithy_xml::decode::try_data(&mut tag)?.as_ref()
.into()
)
?
)
;
builder = builder.set_message(var_15);
}
,
_ => {}
}
}
Ok(builder)
}
#[allow(unused_mut)]
pub fn deser_structure_crate_error_stale_tag_exception_xml_err(
inp: &[u8],
mut builder: crate::error::stale_tag_exception::Builder,
) -> Result<crate::error::stale_tag_exception::Builder, aws_smithy_xml::decode::XmlDecodeError> {
if inp.is_empty() {
return Ok(builder);
}
let mut document = aws_smithy_xml::decode::Document::try_from(inp)?;
#[allow(unused_mut)]
let mut error_decoder = crate::rest_xml_wrapped_errors::error_scope(&mut document)?;
while let Some(mut tag) = error_decoder.next_tag() {
match tag.start_el() {
s if s.matches("message") => {
let var_16 =
Some(
Result::<std::string::String, aws_smithy_xml::decode::XmlDecodeError>::Ok(
aws_smithy_xml::decode::try_data(&mut tag)?.as_ref()
.into()
)
?
)
;
builder = builder.set_message(var_16);
}
,
_ => {}
}
}
Ok(builder)
}
#[allow(unused_mut)]
pub fn deser_structure_crate_error_tag_limit_exceeded_exception_xml_err(
inp: &[u8],
mut builder: crate::error::tag_limit_exceeded_exception::Builder,
) -> Result<
crate::error::tag_limit_exceeded_exception::Builder,
aws_smithy_xml::decode::XmlDecodeError,
> {
if inp.is_empty() {
return Ok(builder);
}
let mut document = aws_smithy_xml::decode::Document::try_from(inp)?;
#[allow(unused_mut)]
let mut error_decoder = crate::rest_xml_wrapped_errors::error_scope(&mut document)?;
while let Some(mut tag) = error_decoder.next_tag() {
match tag.start_el() {
s if s.matches("message") => {
let var_17 =
Some(
Result::<std::string::String, aws_smithy_xml::decode::XmlDecodeError>::Ok(
aws_smithy_xml::decode::try_data(&mut tag)?.as_ref()
.into()
)
?
)
;
builder = builder.set_message(var_17);
}
,
_ => {}
}
}
Ok(builder)
}
#[allow(unused_mut)]
pub fn deser_structure_crate_error_tag_policy_exception_xml_err(
inp: &[u8],
mut builder: crate::error::tag_policy_exception::Builder,
) -> Result<crate::error::tag_policy_exception::Builder, aws_smithy_xml::decode::XmlDecodeError> {
if inp.is_empty() {
return Ok(builder);
}
let mut document = aws_smithy_xml::decode::Document::try_from(inp)?;
#[allow(unused_mut)]
let mut error_decoder = crate::rest_xml_wrapped_errors::error_scope(&mut document)?;
while let Some(mut tag) = error_decoder.next_tag() {
match tag.start_el() {
s if s.matches("message") => {
let var_18 =
Some(
Result::<std::string::String, aws_smithy_xml::decode::XmlDecodeError>::Ok(
aws_smithy_xml::decode::try_data(&mut tag)?.as_ref()
.into()
)
?
)
;
builder = builder.set_message(var_18);
}
,
_ => {}
}
}
Ok(builder)
}
#[allow(unused_mut)]
pub fn deser_structure_crate_error_topic_limit_exceeded_exception_xml_err(
inp: &[u8],
mut builder: crate::error::topic_limit_exceeded_exception::Builder,
) -> Result<
crate::error::topic_limit_exceeded_exception::Builder,
aws_smithy_xml::decode::XmlDecodeError,
> {
if inp.is_empty() {
return Ok(builder);
}
let mut document = aws_smithy_xml::decode::Document::try_from(inp)?;
#[allow(unused_mut)]
let mut error_decoder = crate::rest_xml_wrapped_errors::error_scope(&mut document)?;
while let Some(mut tag) = error_decoder.next_tag() {
match tag.start_el() {
s if s.matches("message") => {
let var_19 =
Some(
Result::<std::string::String, aws_smithy_xml::decode::XmlDecodeError>::Ok(
aws_smithy_xml::decode::try_data(&mut tag)?.as_ref()
.into()
)
?
)
;
builder = builder.set_message(var_19);
}
,
_ => {}
}
}
Ok(builder)
}
#[allow(unused_mut)]
pub fn deser_operation_crate_operation_create_topic(
inp: &[u8],
mut builder: crate::output::create_topic_output::Builder,
) -> Result<crate::output::create_topic_output::Builder, aws_smithy_xml::decode::XmlDecodeError> {
let mut doc = aws_smithy_xml::decode::Document::try_from(inp)?;
#[allow(unused_mut)]
let mut decoder = doc.root_element()?;
#[allow(unused_variables)]
let start_el = decoder.start_el();
if !(start_el.matches("CreateTopicResponse")) {
return Err(aws_smithy_xml::decode::XmlDecodeError::custom(format!(
"invalid root, expected CreateTopicResponse got {:?}",
start_el
)));
}
if let Some(mut result_tag) = decoder.next_tag() {
let start_el = result_tag.start_el();
if !(start_el.matches("CreateTopicResult")) {
return Err(aws_smithy_xml::decode::XmlDecodeError::custom(format!(
"invalid result, expected CreateTopicResult got {:?}",
start_el
)));
}
while let Some(mut tag) = result_tag.next_tag() {
match tag.start_el() {
s if s.matches("TopicArn") => {
let var_20 =
Some(
Result::<std::string::String, aws_smithy_xml::decode::XmlDecodeError>::Ok(
aws_smithy_xml::decode::try_data(&mut tag)?.as_ref()
.into()
)
?
)
;
builder = builder.set_topic_arn(var_20);
}
,
_ => {}
}
}
} else {
return Err(aws_smithy_xml::decode::XmlDecodeError::custom(
"expected CreateTopicResult tag",
));
};
Ok(builder)
}
#[allow(unused_mut)]
pub fn deser_structure_crate_error_resource_not_found_exception_xml_err(
inp: &[u8],
mut builder: crate::error::resource_not_found_exception::Builder,
) -> Result<
crate::error::resource_not_found_exception::Builder,
aws_smithy_xml::decode::XmlDecodeError,
> {
if inp.is_empty() {
return Ok(builder);
}
let mut document = aws_smithy_xml::decode::Document::try_from(inp)?;
#[allow(unused_mut)]
let mut error_decoder = crate::rest_xml_wrapped_errors::error_scope(&mut document)?;
while let Some(mut tag) = error_decoder.next_tag() {
match tag.start_el() {
s if s.matches("message") => {
let var_21 =
Some(
Result::<std::string::String, aws_smithy_xml::decode::XmlDecodeError>::Ok(
aws_smithy_xml::decode::try_data(&mut tag)?.as_ref()
.into()
)
?
)
;
builder = builder.set_message(var_21);
}
,
_ => {}
}
}
Ok(builder)
}
#[allow(unused_mut)]
pub fn deser_operation_crate_operation_get_data_protection_policy(
inp: &[u8],
mut builder: crate::output::get_data_protection_policy_output::Builder,
) -> Result<
crate::output::get_data_protection_policy_output::Builder,
aws_smithy_xml::decode::XmlDecodeError,
> {
let mut doc = aws_smithy_xml::decode::Document::try_from(inp)?;
#[allow(unused_mut)]
let mut decoder = doc.root_element()?;
#[allow(unused_variables)]
let start_el = decoder.start_el();
if !(start_el.matches("GetDataProtectionPolicyResponse")) {
return Err(aws_smithy_xml::decode::XmlDecodeError::custom(format!(
"invalid root, expected GetDataProtectionPolicyResponse got {:?}",
start_el
)));
}
if let Some(mut result_tag) = decoder.next_tag() {
let start_el = result_tag.start_el();
if !(start_el.matches("GetDataProtectionPolicyResult")) {
return Err(aws_smithy_xml::decode::XmlDecodeError::custom(format!(
"invalid result, expected GetDataProtectionPolicyResult got {:?}",
start_el
)));
}
while let Some(mut tag) = result_tag.next_tag() {
match tag.start_el() {
s if s.matches("DataProtectionPolicy") => {
let var_22 =
Some(
Result::<std::string::String, aws_smithy_xml::decode::XmlDecodeError>::Ok(
aws_smithy_xml::decode::try_data(&mut tag)?.as_ref()
.into()
)
?
)
;
builder = builder.set_data_protection_policy(var_22);
}
,
_ => {}
}
}
} else {
return Err(aws_smithy_xml::decode::XmlDecodeError::custom(
"expected GetDataProtectionPolicyResult tag",
));
};
Ok(builder)
}
#[allow(unused_mut)]
pub fn deser_operation_crate_operation_get_endpoint_attributes(
inp: &[u8],
mut builder: crate::output::get_endpoint_attributes_output::Builder,
) -> Result<
crate::output::get_endpoint_attributes_output::Builder,
aws_smithy_xml::decode::XmlDecodeError,
> {
let mut doc = aws_smithy_xml::decode::Document::try_from(inp)?;
#[allow(unused_mut)]
let mut decoder = doc.root_element()?;
#[allow(unused_variables)]
let start_el = decoder.start_el();
if !(start_el.matches("GetEndpointAttributesResponse")) {
return Err(aws_smithy_xml::decode::XmlDecodeError::custom(format!(
"invalid root, expected GetEndpointAttributesResponse got {:?}",
start_el
)));
}
if let Some(mut result_tag) = decoder.next_tag() {
let start_el = result_tag.start_el();
if !(start_el.matches("GetEndpointAttributesResult")) {
return Err(aws_smithy_xml::decode::XmlDecodeError::custom(format!(
"invalid result, expected GetEndpointAttributesResult got {:?}",
start_el
)));
}
while let Some(mut tag) = result_tag.next_tag() {
match tag.start_el() {
s if s.matches("Attributes") => {
let var_23 =
Some(
crate::xml_deser::deser_map_com_amazonaws_sns_map_string_to_string(&mut tag)
?
)
;
builder = builder.set_attributes(var_23);
}
,
_ => {}
}
}
} else {
return Err(aws_smithy_xml::decode::XmlDecodeError::custom(
"expected GetEndpointAttributesResult tag",
));
};
Ok(builder)
}
#[allow(unused_mut)]
pub fn deser_operation_crate_operation_get_platform_application_attributes(
inp: &[u8],
mut builder: crate::output::get_platform_application_attributes_output::Builder,
) -> Result<
crate::output::get_platform_application_attributes_output::Builder,
aws_smithy_xml::decode::XmlDecodeError,
> {
let mut doc = aws_smithy_xml::decode::Document::try_from(inp)?;
#[allow(unused_mut)]
let mut decoder = doc.root_element()?;
#[allow(unused_variables)]
let start_el = decoder.start_el();
if !(start_el.matches("GetPlatformApplicationAttributesResponse")) {
return Err(aws_smithy_xml::decode::XmlDecodeError::custom(format!(
"invalid root, expected GetPlatformApplicationAttributesResponse got {:?}",
start_el
)));
}
if let Some(mut result_tag) = decoder.next_tag() {
let start_el = result_tag.start_el();
if !(start_el.matches("GetPlatformApplicationAttributesResult")) {
return Err(aws_smithy_xml::decode::XmlDecodeError::custom(format!(
"invalid result, expected GetPlatformApplicationAttributesResult got {:?}",
start_el
)));
}
while let Some(mut tag) = result_tag.next_tag() {
match tag.start_el() {
s if s.matches("Attributes") => {
let var_24 =
Some(
crate::xml_deser::deser_map_com_amazonaws_sns_map_string_to_string(&mut tag)
?
)
;
builder = builder.set_attributes(var_24);
}
,
_ => {}
}
}
} else {
return Err(aws_smithy_xml::decode::XmlDecodeError::custom(
"expected GetPlatformApplicationAttributesResult tag",
));
};
Ok(builder)
}
#[allow(unused_mut)]
pub fn deser_operation_crate_operation_get_sms_attributes(
inp: &[u8],
mut builder: crate::output::get_sms_attributes_output::Builder,
) -> Result<crate::output::get_sms_attributes_output::Builder, aws_smithy_xml::decode::XmlDecodeError>
{
let mut doc = aws_smithy_xml::decode::Document::try_from(inp)?;
#[allow(unused_mut)]
let mut decoder = doc.root_element()?;
#[allow(unused_variables)]
let start_el = decoder.start_el();
if !(start_el.matches("GetSMSAttributesResponse")) {
return Err(aws_smithy_xml::decode::XmlDecodeError::custom(format!(
"invalid root, expected GetSMSAttributesResponse got {:?}",
start_el
)));
}
if let Some(mut result_tag) = decoder.next_tag() {
let start_el = result_tag.start_el();
if !(start_el.matches("GetSMSAttributesResult")) {
return Err(aws_smithy_xml::decode::XmlDecodeError::custom(format!(
"invalid result, expected GetSMSAttributesResult got {:?}",
start_el
)));
}
while let Some(mut tag) = result_tag.next_tag() {
match tag.start_el() {
s if s.matches("attributes") => {
let var_25 =
Some(
crate::xml_deser::deser_map_com_amazonaws_sns_map_string_to_string(&mut tag)
?
)
;
builder = builder.set_attributes(var_25);
}
,
_ => {}
}
}
} else {
return Err(aws_smithy_xml::decode::XmlDecodeError::custom(
"expected GetSMSAttributesResult tag",
));
};
Ok(builder)
}
#[allow(unused_mut)]
pub fn deser_operation_crate_operation_get_sms_sandbox_account_status(
inp: &[u8],
mut builder: crate::output::get_sms_sandbox_account_status_output::Builder,
) -> Result<
crate::output::get_sms_sandbox_account_status_output::Builder,
aws_smithy_xml::decode::XmlDecodeError,
> {
let mut doc = aws_smithy_xml::decode::Document::try_from(inp)?;
#[allow(unused_mut)]
let mut decoder = doc.root_element()?;
#[allow(unused_variables)]
let start_el = decoder.start_el();
if !(start_el.matches("GetSMSSandboxAccountStatusResponse")) {
return Err(aws_smithy_xml::decode::XmlDecodeError::custom(format!(
"invalid root, expected GetSMSSandboxAccountStatusResponse got {:?}",
start_el
)));
}
if let Some(mut result_tag) = decoder.next_tag() {
let start_el = result_tag.start_el();
if !(start_el.matches("GetSMSSandboxAccountStatusResult")) {
return Err(aws_smithy_xml::decode::XmlDecodeError::custom(format!(
"invalid result, expected GetSMSSandboxAccountStatusResult got {:?}",
start_el
)));
}
while let Some(mut tag) = result_tag.next_tag() {
match tag.start_el() {
s if s.matches("IsInSandbox") => {
let var_26 =
Some(
{
<bool as aws_smithy_types::primitive::Parse>::parse_smithy_primitive(
aws_smithy_xml::decode::try_data(&mut tag)?.as_ref()
)
.map_err(|_|aws_smithy_xml::decode::XmlDecodeError::custom("expected (boolean: `com.amazonaws.sns#boolean`)"))
}
?
)
;
builder = builder.set_is_in_sandbox(var_26);
}
,
_ => {}
}
}
} else {
return Err(aws_smithy_xml::decode::XmlDecodeError::custom(
"expected GetSMSSandboxAccountStatusResult tag",
));
};
Ok(builder)
}
#[allow(unused_mut)]
pub fn deser_operation_crate_operation_get_subscription_attributes(
inp: &[u8],
mut builder: crate::output::get_subscription_attributes_output::Builder,
) -> Result<
crate::output::get_subscription_attributes_output::Builder,
aws_smithy_xml::decode::XmlDecodeError,
> {
let mut doc = aws_smithy_xml::decode::Document::try_from(inp)?;
#[allow(unused_mut)]
let mut decoder = doc.root_element()?;
#[allow(unused_variables)]
let start_el = decoder.start_el();
if !(start_el.matches("GetSubscriptionAttributesResponse")) {
return Err(aws_smithy_xml::decode::XmlDecodeError::custom(format!(
"invalid root, expected GetSubscriptionAttributesResponse got {:?}",
start_el
)));
}
if let Some(mut result_tag) = decoder.next_tag() {
let start_el = result_tag.start_el();
if !(start_el.matches("GetSubscriptionAttributesResult")) {
return Err(aws_smithy_xml::decode::XmlDecodeError::custom(format!(
"invalid result, expected GetSubscriptionAttributesResult got {:?}",
start_el
)));
}
while let Some(mut tag) = result_tag.next_tag() {
match tag.start_el() {
s if s.matches("Attributes") => {
let var_27 =
Some(
crate::xml_deser::deser_map_com_amazonaws_sns_subscription_attributes_map(&mut tag)
?
)
;
builder = builder.set_attributes(var_27);
}
,
_ => {}
}
}
} else {
return Err(aws_smithy_xml::decode::XmlDecodeError::custom(
"expected GetSubscriptionAttributesResult tag",
));
};
Ok(builder)
}
#[allow(unused_mut)]
pub fn deser_operation_crate_operation_get_topic_attributes(
inp: &[u8],
mut builder: crate::output::get_topic_attributes_output::Builder,
) -> Result<
crate::output::get_topic_attributes_output::Builder,
aws_smithy_xml::decode::XmlDecodeError,
> {
let mut doc = aws_smithy_xml::decode::Document::try_from(inp)?;
#[allow(unused_mut)]
let mut decoder = doc.root_element()?;
#[allow(unused_variables)]
let start_el = decoder.start_el();
if !(start_el.matches("GetTopicAttributesResponse")) {
return Err(aws_smithy_xml::decode::XmlDecodeError::custom(format!(
"invalid root, expected GetTopicAttributesResponse got {:?}",
start_el
)));
}
if let Some(mut result_tag) = decoder.next_tag() {
let start_el = result_tag.start_el();
if !(start_el.matches("GetTopicAttributesResult")) {
return Err(aws_smithy_xml::decode::XmlDecodeError::custom(format!(
"invalid result, expected GetTopicAttributesResult got {:?}",
start_el
)));
}
while let Some(mut tag) = result_tag.next_tag() {
match tag.start_el() {
s if s.matches("Attributes") => {
let var_28 =
Some(
crate::xml_deser::deser_map_com_amazonaws_sns_topic_attributes_map(&mut tag)
?
)
;
builder = builder.set_attributes(var_28);
}
,
_ => {}
}
}
} else {
return Err(aws_smithy_xml::decode::XmlDecodeError::custom(
"expected GetTopicAttributesResult tag",
));
};
Ok(builder)
}
#[allow(unused_mut)]
pub fn deser_operation_crate_operation_list_endpoints_by_platform_application(
inp: &[u8],
mut builder: crate::output::list_endpoints_by_platform_application_output::Builder,
) -> Result<
crate::output::list_endpoints_by_platform_application_output::Builder,
aws_smithy_xml::decode::XmlDecodeError,
> {
let mut doc = aws_smithy_xml::decode::Document::try_from(inp)?;
#[allow(unused_mut)]
let mut decoder = doc.root_element()?;
#[allow(unused_variables)]
let start_el = decoder.start_el();
if !(start_el.matches("ListEndpointsByPlatformApplicationResponse")) {
return Err(aws_smithy_xml::decode::XmlDecodeError::custom(format!(
"invalid root, expected ListEndpointsByPlatformApplicationResponse got {:?}",
start_el
)));
}
if let Some(mut result_tag) = decoder.next_tag() {
let start_el = result_tag.start_el();
if !(start_el.matches("ListEndpointsByPlatformApplicationResult")) {
return Err(aws_smithy_xml::decode::XmlDecodeError::custom(format!(
"invalid result, expected ListEndpointsByPlatformApplicationResult got {:?}",
start_el
)));
}
while let Some(mut tag) = result_tag.next_tag() {
match tag.start_el() {
s if s.matches("Endpoints") => {
let var_29 =
Some(
crate::xml_deser::deser_list_com_amazonaws_sns_list_of_endpoints(&mut tag)
?
)
;
builder = builder.set_endpoints(var_29);
}
,
s if s.matches("NextToken") => {
let var_30 =
Some(
Result::<std::string::String, aws_smithy_xml::decode::XmlDecodeError>::Ok(
aws_smithy_xml::decode::try_data(&mut tag)?.as_ref()
.into()
)
?
)
;
builder = builder.set_next_token(var_30);
}
,
_ => {}
}
}
} else {
return Err(aws_smithy_xml::decode::XmlDecodeError::custom(
"expected ListEndpointsByPlatformApplicationResult tag",
));
};
Ok(builder)
}
#[allow(unused_mut)]
pub fn deser_structure_crate_error_validation_exception_xml_err(
inp: &[u8],
mut builder: crate::error::validation_exception::Builder,
) -> Result<crate::error::validation_exception::Builder, aws_smithy_xml::decode::XmlDecodeError> {
if inp.is_empty() {
return Ok(builder);
}
let mut document = aws_smithy_xml::decode::Document::try_from(inp)?;
#[allow(unused_mut)]
let mut error_decoder = crate::rest_xml_wrapped_errors::error_scope(&mut document)?;
while let Some(mut tag) = error_decoder.next_tag() {
match tag.start_el() {
s if s.matches("Message") => {
let var_31 =
Some(
Result::<std::string::String, aws_smithy_xml::decode::XmlDecodeError>::Ok(
aws_smithy_xml::decode::try_data(&mut tag)?.as_ref()
.into()
)
?
)
;
builder = builder.set_message(var_31);
}
,
_ => {}
}
}
Ok(builder)
}
#[allow(unused_mut)]
pub fn deser_operation_crate_operation_list_origination_numbers(
inp: &[u8],
mut builder: crate::output::list_origination_numbers_output::Builder,
) -> Result<
crate::output::list_origination_numbers_output::Builder,
aws_smithy_xml::decode::XmlDecodeError,
> {
let mut doc = aws_smithy_xml::decode::Document::try_from(inp)?;
#[allow(unused_mut)]
let mut decoder = doc.root_element()?;
#[allow(unused_variables)]
let start_el = decoder.start_el();
if !(start_el.matches("ListOriginationNumbersResponse")) {
return Err(aws_smithy_xml::decode::XmlDecodeError::custom(format!(
"invalid root, expected ListOriginationNumbersResponse got {:?}",
start_el
)));
}
if let Some(mut result_tag) = decoder.next_tag() {
let start_el = result_tag.start_el();
if !(start_el.matches("ListOriginationNumbersResult")) {
return Err(aws_smithy_xml::decode::XmlDecodeError::custom(format!(
"invalid result, expected ListOriginationNumbersResult got {:?}",
start_el
)));
}
while let Some(mut tag) = result_tag.next_tag() {
match tag.start_el() {
s if s.matches("NextToken") => {
let var_32 =
Some(
Result::<std::string::String, aws_smithy_xml::decode::XmlDecodeError>::Ok(
aws_smithy_xml::decode::try_data(&mut tag)?.as_ref()
.into()
)
?
)
;
builder = builder.set_next_token(var_32);
}
,
s if s.matches("PhoneNumbers") => {
let var_33 =
Some(
crate::xml_deser::deser_list_com_amazonaws_sns_phone_number_information_list(&mut tag)
?
)
;
builder = builder.set_phone_numbers(var_33);
}
,
_ => {}
}
}
} else {
return Err(aws_smithy_xml::decode::XmlDecodeError::custom(
"expected ListOriginationNumbersResult tag",
));
};
Ok(builder)
}
#[allow(unused_mut)]
pub fn deser_operation_crate_operation_list_phone_numbers_opted_out(
inp: &[u8],
mut builder: crate::output::list_phone_numbers_opted_out_output::Builder,
) -> Result<
crate::output::list_phone_numbers_opted_out_output::Builder,
aws_smithy_xml::decode::XmlDecodeError,
> {
let mut doc = aws_smithy_xml::decode::Document::try_from(inp)?;
#[allow(unused_mut)]
let mut decoder = doc.root_element()?;
#[allow(unused_variables)]
let start_el = decoder.start_el();
if !(start_el.matches("ListPhoneNumbersOptedOutResponse")) {
return Err(aws_smithy_xml::decode::XmlDecodeError::custom(format!(
"invalid root, expected ListPhoneNumbersOptedOutResponse got {:?}",
start_el
)));
}
if let Some(mut result_tag) = decoder.next_tag() {
let start_el = result_tag.start_el();
if !(start_el.matches("ListPhoneNumbersOptedOutResult")) {
return Err(aws_smithy_xml::decode::XmlDecodeError::custom(format!(
"invalid result, expected ListPhoneNumbersOptedOutResult got {:?}",
start_el
)));
}
while let Some(mut tag) = result_tag.next_tag() {
match tag.start_el() {
s if s.matches("phoneNumbers") => {
let var_34 =
Some(
crate::xml_deser::deser_list_com_amazonaws_sns_phone_number_list(&mut tag)
?
)
;
builder = builder.set_phone_numbers(var_34);
}
,
s if s.matches("nextToken") => {
let var_35 =
Some(
Result::<std::string::String, aws_smithy_xml::decode::XmlDecodeError>::Ok(
aws_smithy_xml::decode::try_data(&mut tag)?.as_ref()
.into()
)
?
)
;
builder = builder.set_next_token(var_35);
}
,
_ => {}
}
}
} else {
return Err(aws_smithy_xml::decode::XmlDecodeError::custom(
"expected ListPhoneNumbersOptedOutResult tag",
));
};
Ok(builder)
}
#[allow(unused_mut)]
pub fn deser_operation_crate_operation_list_platform_applications(
inp: &[u8],
mut builder: crate::output::list_platform_applications_output::Builder,
) -> Result<
crate::output::list_platform_applications_output::Builder,
aws_smithy_xml::decode::XmlDecodeError,
> {
let mut doc = aws_smithy_xml::decode::Document::try_from(inp)?;
#[allow(unused_mut)]
let mut decoder = doc.root_element()?;
#[allow(unused_variables)]
let start_el = decoder.start_el();
if !(start_el.matches("ListPlatformApplicationsResponse")) {
return Err(aws_smithy_xml::decode::XmlDecodeError::custom(format!(
"invalid root, expected ListPlatformApplicationsResponse got {:?}",
start_el
)));
}
if let Some(mut result_tag) = decoder.next_tag() {
let start_el = result_tag.start_el();
if !(start_el.matches("ListPlatformApplicationsResult")) {
return Err(aws_smithy_xml::decode::XmlDecodeError::custom(format!(
"invalid result, expected ListPlatformApplicationsResult got {:?}",
start_el
)));
}
while let Some(mut tag) = result_tag.next_tag() {
match tag.start_el() {
s if s.matches("PlatformApplications") => {
let var_36 =
Some(
crate::xml_deser::deser_list_com_amazonaws_sns_list_of_platform_applications(&mut tag)
?
)
;
builder = builder.set_platform_applications(var_36);
}
,
s if s.matches("NextToken") => {
let var_37 =
Some(
Result::<std::string::String, aws_smithy_xml::decode::XmlDecodeError>::Ok(
aws_smithy_xml::decode::try_data(&mut tag)?.as_ref()
.into()
)
?
)
;
builder = builder.set_next_token(var_37);
}
,
_ => {}
}
}
} else {
return Err(aws_smithy_xml::decode::XmlDecodeError::custom(
"expected ListPlatformApplicationsResult tag",
));
};
Ok(builder)
}
#[allow(unused_mut)]
pub fn deser_operation_crate_operation_list_sms_sandbox_phone_numbers(
inp: &[u8],
mut builder: crate::output::list_sms_sandbox_phone_numbers_output::Builder,
) -> Result<
crate::output::list_sms_sandbox_phone_numbers_output::Builder,
aws_smithy_xml::decode::XmlDecodeError,
> {
let mut doc = aws_smithy_xml::decode::Document::try_from(inp)?;
#[allow(unused_mut)]
let mut decoder = doc.root_element()?;
#[allow(unused_variables)]
let start_el = decoder.start_el();
if !(start_el.matches("ListSMSSandboxPhoneNumbersResponse")) {
return Err(aws_smithy_xml::decode::XmlDecodeError::custom(format!(
"invalid root, expected ListSMSSandboxPhoneNumbersResponse got {:?}",
start_el
)));
}
if let Some(mut result_tag) = decoder.next_tag() {
let start_el = result_tag.start_el();
if !(start_el.matches("ListSMSSandboxPhoneNumbersResult")) {
return Err(aws_smithy_xml::decode::XmlDecodeError::custom(format!(
"invalid result, expected ListSMSSandboxPhoneNumbersResult got {:?}",
start_el
)));
}
while let Some(mut tag) = result_tag.next_tag() {
match tag.start_el() {
s if s.matches("PhoneNumbers") => {
let var_38 =
Some(
crate::xml_deser::deser_list_com_amazonaws_sns_sms_sandbox_phone_number_list(&mut tag)
?
)
;
builder = builder.set_phone_numbers(var_38);
}
,
s if s.matches("NextToken") => {
let var_39 =
Some(
Result::<std::string::String, aws_smithy_xml::decode::XmlDecodeError>::Ok(
aws_smithy_xml::decode::try_data(&mut tag)?.as_ref()
.into()
)
?
)
;
builder = builder.set_next_token(var_39);
}
,
_ => {}
}
}
} else {
return Err(aws_smithy_xml::decode::XmlDecodeError::custom(
"expected ListSMSSandboxPhoneNumbersResult tag",
));
};
Ok(builder)
}
#[allow(unused_mut)]
pub fn deser_operation_crate_operation_list_subscriptions(
inp: &[u8],
mut builder: crate::output::list_subscriptions_output::Builder,
) -> Result<crate::output::list_subscriptions_output::Builder, aws_smithy_xml::decode::XmlDecodeError>
{
let mut doc = aws_smithy_xml::decode::Document::try_from(inp)?;
#[allow(unused_mut)]
let mut decoder = doc.root_element()?;
#[allow(unused_variables)]
let start_el = decoder.start_el();
if !(start_el.matches("ListSubscriptionsResponse")) {
return Err(aws_smithy_xml::decode::XmlDecodeError::custom(format!(
"invalid root, expected ListSubscriptionsResponse got {:?}",
start_el
)));
}
if let Some(mut result_tag) = decoder.next_tag() {
let start_el = result_tag.start_el();
if !(start_el.matches("ListSubscriptionsResult")) {
return Err(aws_smithy_xml::decode::XmlDecodeError::custom(format!(
"invalid result, expected ListSubscriptionsResult got {:?}",
start_el
)));
}
while let Some(mut tag) = result_tag.next_tag() {
match tag.start_el() {
s if s.matches("Subscriptions") => {
let var_40 =
Some(
crate::xml_deser::deser_list_com_amazonaws_sns_subscriptions_list(&mut tag)
?
)
;
builder = builder.set_subscriptions(var_40);
}
,
s if s.matches("NextToken") => {
let var_41 =
Some(
Result::<std::string::String, aws_smithy_xml::decode::XmlDecodeError>::Ok(
aws_smithy_xml::decode::try_data(&mut tag)?.as_ref()
.into()
)
?
)
;
builder = builder.set_next_token(var_41);
}
,
_ => {}
}
}
} else {
return Err(aws_smithy_xml::decode::XmlDecodeError::custom(
"expected ListSubscriptionsResult tag",
));
};
Ok(builder)
}
#[allow(unused_mut)]
pub fn deser_operation_crate_operation_list_subscriptions_by_topic(
inp: &[u8],
mut builder: crate::output::list_subscriptions_by_topic_output::Builder,
) -> Result<
crate::output::list_subscriptions_by_topic_output::Builder,
aws_smithy_xml::decode::XmlDecodeError,
> {
let mut doc = aws_smithy_xml::decode::Document::try_from(inp)?;
#[allow(unused_mut)]
let mut decoder = doc.root_element()?;
#[allow(unused_variables)]
let start_el = decoder.start_el();
if !(start_el.matches("ListSubscriptionsByTopicResponse")) {
return Err(aws_smithy_xml::decode::XmlDecodeError::custom(format!(
"invalid root, expected ListSubscriptionsByTopicResponse got {:?}",
start_el
)));
}
if let Some(mut result_tag) = decoder.next_tag() {
let start_el = result_tag.start_el();
if !(start_el.matches("ListSubscriptionsByTopicResult")) {
return Err(aws_smithy_xml::decode::XmlDecodeError::custom(format!(
"invalid result, expected ListSubscriptionsByTopicResult got {:?}",
start_el
)));
}
while let Some(mut tag) = result_tag.next_tag() {
match tag.start_el() {
s if s.matches("Subscriptions") => {
let var_42 =
Some(
crate::xml_deser::deser_list_com_amazonaws_sns_subscriptions_list(&mut tag)
?
)
;
builder = builder.set_subscriptions(var_42);
}
,
s if s.matches("NextToken") => {
let var_43 =
Some(
Result::<std::string::String, aws_smithy_xml::decode::XmlDecodeError>::Ok(
aws_smithy_xml::decode::try_data(&mut tag)?.as_ref()
.into()
)
?
)
;
builder = builder.set_next_token(var_43);
}
,
_ => {}
}
}
} else {
return Err(aws_smithy_xml::decode::XmlDecodeError::custom(
"expected ListSubscriptionsByTopicResult tag",
));
};
Ok(builder)
}
#[allow(unused_mut)]
pub fn deser_operation_crate_operation_list_tags_for_resource(
inp: &[u8],
mut builder: crate::output::list_tags_for_resource_output::Builder,
) -> Result<
crate::output::list_tags_for_resource_output::Builder,
aws_smithy_xml::decode::XmlDecodeError,
> {
let mut doc = aws_smithy_xml::decode::Document::try_from(inp)?;
#[allow(unused_mut)]
let mut decoder = doc.root_element()?;
#[allow(unused_variables)]
let start_el = decoder.start_el();
if !(start_el.matches("ListTagsForResourceResponse")) {
return Err(aws_smithy_xml::decode::XmlDecodeError::custom(format!(
"invalid root, expected ListTagsForResourceResponse got {:?}",
start_el
)));
}
if let Some(mut result_tag) = decoder.next_tag() {
let start_el = result_tag.start_el();
if !(start_el.matches("ListTagsForResourceResult")) {
return Err(aws_smithy_xml::decode::XmlDecodeError::custom(format!(
"invalid result, expected ListTagsForResourceResult got {:?}",
start_el
)));
}
while let Some(mut tag) = result_tag.next_tag() {
match tag.start_el() {
s if s.matches("Tags") => {
let var_44 =
Some(
crate::xml_deser::deser_list_com_amazonaws_sns_tag_list(&mut tag)
?
)
;
builder = builder.set_tags(var_44);
}
,
_ => {}
}
}
} else {
return Err(aws_smithy_xml::decode::XmlDecodeError::custom(
"expected ListTagsForResourceResult tag",
));
};
Ok(builder)
}
#[allow(unused_mut)]
pub fn deser_operation_crate_operation_list_topics(
inp: &[u8],
mut builder: crate::output::list_topics_output::Builder,
) -> Result<crate::output::list_topics_output::Builder, aws_smithy_xml::decode::XmlDecodeError> {
let mut doc = aws_smithy_xml::decode::Document::try_from(inp)?;
#[allow(unused_mut)]
let mut decoder = doc.root_element()?;
#[allow(unused_variables)]
let start_el = decoder.start_el();
if !(start_el.matches("ListTopicsResponse")) {
return Err(aws_smithy_xml::decode::XmlDecodeError::custom(format!(
"invalid root, expected ListTopicsResponse got {:?}",
start_el
)));
}
if let Some(mut result_tag) = decoder.next_tag() {
let start_el = result_tag.start_el();
if !(start_el.matches("ListTopicsResult")) {
return Err(aws_smithy_xml::decode::XmlDecodeError::custom(format!(
"invalid result, expected ListTopicsResult got {:?}",
start_el
)));
}
while let Some(mut tag) = result_tag.next_tag() {
match tag.start_el() {
s if s.matches("Topics") => {
let var_45 =
Some(
crate::xml_deser::deser_list_com_amazonaws_sns_topics_list(&mut tag)
?
)
;
builder = builder.set_topics(var_45);
}
,
s if s.matches("NextToken") => {
let var_46 =
Some(
Result::<std::string::String, aws_smithy_xml::decode::XmlDecodeError>::Ok(
aws_smithy_xml::decode::try_data(&mut tag)?.as_ref()
.into()
)
?
)
;
builder = builder.set_next_token(var_46);
}
,
_ => {}
}
}
} else {
return Err(aws_smithy_xml::decode::XmlDecodeError::custom(
"expected ListTopicsResult tag",
));
};
Ok(builder)
}
#[allow(unused_mut)]
pub fn deser_structure_crate_error_endpoint_disabled_exception_xml_err(
inp: &[u8],
mut builder: crate::error::endpoint_disabled_exception::Builder,
) -> Result<
crate::error::endpoint_disabled_exception::Builder,
aws_smithy_xml::decode::XmlDecodeError,
> {
if inp.is_empty() {
return Ok(builder);
}
let mut document = aws_smithy_xml::decode::Document::try_from(inp)?;
#[allow(unused_mut)]
let mut error_decoder = crate::rest_xml_wrapped_errors::error_scope(&mut document)?;
while let Some(mut tag) = error_decoder.next_tag() {
match tag.start_el() {
s if s.matches("message") => {
let var_47 =
Some(
Result::<std::string::String, aws_smithy_xml::decode::XmlDecodeError>::Ok(
aws_smithy_xml::decode::try_data(&mut tag)?.as_ref()
.into()
)
?
)
;
builder = builder.set_message(var_47);
}
,
_ => {}
}
}
Ok(builder)
}
#[allow(unused_mut)]
pub fn deser_structure_crate_error_invalid_parameter_value_exception_xml_err(
inp: &[u8],
mut builder: crate::error::invalid_parameter_value_exception::Builder,
) -> Result<
crate::error::invalid_parameter_value_exception::Builder,
aws_smithy_xml::decode::XmlDecodeError,
> {
if inp.is_empty() {
return Ok(builder);
}
let mut document = aws_smithy_xml::decode::Document::try_from(inp)?;
#[allow(unused_mut)]
let mut error_decoder = crate::rest_xml_wrapped_errors::error_scope(&mut document)?;
while let Some(mut tag) = error_decoder.next_tag() {
match tag.start_el() {
s if s.matches("message") => {
let var_48 =
Some(
Result::<std::string::String, aws_smithy_xml::decode::XmlDecodeError>::Ok(
aws_smithy_xml::decode::try_data(&mut tag)?.as_ref()
.into()
)
?
)
;
builder = builder.set_message(var_48);
}
,
_ => {}
}
}
Ok(builder)
}
#[allow(unused_mut)]
pub fn deser_structure_crate_error_kms_access_denied_exception_xml_err(
inp: &[u8],
mut builder: crate::error::kms_access_denied_exception::Builder,
) -> Result<
crate::error::kms_access_denied_exception::Builder,
aws_smithy_xml::decode::XmlDecodeError,
> {
if inp.is_empty() {
return Ok(builder);
}
let mut document = aws_smithy_xml::decode::Document::try_from(inp)?;
#[allow(unused_mut)]
let mut error_decoder = crate::rest_xml_wrapped_errors::error_scope(&mut document)?;
while let Some(mut tag) = error_decoder.next_tag() {
match tag.start_el() {
s if s.matches("message") => {
let var_49 =
Some(
Result::<std::string::String, aws_smithy_xml::decode::XmlDecodeError>::Ok(
aws_smithy_xml::decode::try_data(&mut tag)?.as_ref()
.into()
)
?
)
;
builder = builder.set_message(var_49);
}
,
_ => {}
}
}
Ok(builder)
}
#[allow(unused_mut)]
pub fn deser_structure_crate_error_kms_disabled_exception_xml_err(
inp: &[u8],
mut builder: crate::error::kms_disabled_exception::Builder,
) -> Result<crate::error::kms_disabled_exception::Builder, aws_smithy_xml::decode::XmlDecodeError> {
if inp.is_empty() {
return Ok(builder);
}
let mut document = aws_smithy_xml::decode::Document::try_from(inp)?;
#[allow(unused_mut)]
let mut error_decoder = crate::rest_xml_wrapped_errors::error_scope(&mut document)?;
while let Some(mut tag) = error_decoder.next_tag() {
match tag.start_el() {
s if s.matches("message") => {
let var_50 =
Some(
Result::<std::string::String, aws_smithy_xml::decode::XmlDecodeError>::Ok(
aws_smithy_xml::decode::try_data(&mut tag)?.as_ref()
.into()
)
?
)
;
builder = builder.set_message(var_50);
}
,
_ => {}
}
}
Ok(builder)
}
#[allow(unused_mut)]
pub fn deser_structure_crate_error_kms_invalid_state_exception_xml_err(
inp: &[u8],
mut builder: crate::error::kms_invalid_state_exception::Builder,
) -> Result<
crate::error::kms_invalid_state_exception::Builder,
aws_smithy_xml::decode::XmlDecodeError,
> {
if inp.is_empty() {
return Ok(builder);
}
let mut document = aws_smithy_xml::decode::Document::try_from(inp)?;
#[allow(unused_mut)]
let mut error_decoder = crate::rest_xml_wrapped_errors::error_scope(&mut document)?;
while let Some(mut tag) = error_decoder.next_tag() {
match tag.start_el() {
s if s.matches("message") => {
let var_51 =
Some(
Result::<std::string::String, aws_smithy_xml::decode::XmlDecodeError>::Ok(
aws_smithy_xml::decode::try_data(&mut tag)?.as_ref()
.into()
)
?
)
;
builder = builder.set_message(var_51);
}
,
_ => {}
}
}
Ok(builder)
}
#[allow(unused_mut)]
pub fn deser_structure_crate_error_kms_not_found_exception_xml_err(
inp: &[u8],
mut builder: crate::error::kms_not_found_exception::Builder,
) -> Result<crate::error::kms_not_found_exception::Builder, aws_smithy_xml::decode::XmlDecodeError>
{
if inp.is_empty() {
return Ok(builder);
}
let mut document = aws_smithy_xml::decode::Document::try_from(inp)?;
#[allow(unused_mut)]
let mut error_decoder = crate::rest_xml_wrapped_errors::error_scope(&mut document)?;
while let Some(mut tag) = error_decoder.next_tag() {
match tag.start_el() {
s if s.matches("message") => {
let var_52 =
Some(
Result::<std::string::String, aws_smithy_xml::decode::XmlDecodeError>::Ok(
aws_smithy_xml::decode::try_data(&mut tag)?.as_ref()
.into()
)
?
)
;
builder = builder.set_message(var_52);
}
,
_ => {}
}
}
Ok(builder)
}
#[allow(unused_mut)]
pub fn deser_structure_crate_error_kms_opt_in_required_xml_err(
inp: &[u8],
mut builder: crate::error::kms_opt_in_required::Builder,
) -> Result<crate::error::kms_opt_in_required::Builder, aws_smithy_xml::decode::XmlDecodeError> {
if inp.is_empty() {
return Ok(builder);
}
let mut document = aws_smithy_xml::decode::Document::try_from(inp)?;
#[allow(unused_mut)]
let mut error_decoder = crate::rest_xml_wrapped_errors::error_scope(&mut document)?;
while let Some(mut tag) = error_decoder.next_tag() {
match tag.start_el() {
s if s.matches("message") => {
let var_53 =
Some(
Result::<std::string::String, aws_smithy_xml::decode::XmlDecodeError>::Ok(
aws_smithy_xml::decode::try_data(&mut tag)?.as_ref()
.into()
)
?
)
;
builder = builder.set_message(var_53);
}
,
_ => {}
}
}
Ok(builder)
}
#[allow(unused_mut)]
pub fn deser_structure_crate_error_kms_throttling_exception_xml_err(
inp: &[u8],
mut builder: crate::error::kms_throttling_exception::Builder,
) -> Result<crate::error::kms_throttling_exception::Builder, aws_smithy_xml::decode::XmlDecodeError>
{
if inp.is_empty() {
return Ok(builder);
}
let mut document = aws_smithy_xml::decode::Document::try_from(inp)?;
#[allow(unused_mut)]
let mut error_decoder = crate::rest_xml_wrapped_errors::error_scope(&mut document)?;
while let Some(mut tag) = error_decoder.next_tag() {
match tag.start_el() {
s if s.matches("message") => {
let var_54 =
Some(
Result::<std::string::String, aws_smithy_xml::decode::XmlDecodeError>::Ok(
aws_smithy_xml::decode::try_data(&mut tag)?.as_ref()
.into()
)
?
)
;
builder = builder.set_message(var_54);
}
,
_ => {}
}
}
Ok(builder)
}
#[allow(unused_mut)]
pub fn deser_structure_crate_error_platform_application_disabled_exception_xml_err(
inp: &[u8],
mut builder: crate::error::platform_application_disabled_exception::Builder,
) -> Result<
crate::error::platform_application_disabled_exception::Builder,
aws_smithy_xml::decode::XmlDecodeError,
> {
if inp.is_empty() {
return Ok(builder);
}
let mut document = aws_smithy_xml::decode::Document::try_from(inp)?;
#[allow(unused_mut)]
let mut error_decoder = crate::rest_xml_wrapped_errors::error_scope(&mut document)?;
while let Some(mut tag) = error_decoder.next_tag() {
match tag.start_el() {
s if s.matches("message") => {
let var_55 =
Some(
Result::<std::string::String, aws_smithy_xml::decode::XmlDecodeError>::Ok(
aws_smithy_xml::decode::try_data(&mut tag)?.as_ref()
.into()
)
?
)
;
builder = builder.set_message(var_55);
}
,
_ => {}
}
}
Ok(builder)
}
#[allow(unused_mut)]
pub fn deser_operation_crate_operation_publish(
inp: &[u8],
mut builder: crate::output::publish_output::Builder,
) -> Result<crate::output::publish_output::Builder, aws_smithy_xml::decode::XmlDecodeError> {
let mut doc = aws_smithy_xml::decode::Document::try_from(inp)?;
#[allow(unused_mut)]
let mut decoder = doc.root_element()?;
#[allow(unused_variables)]
let start_el = decoder.start_el();
if !(start_el.matches("PublishResponse")) {
return Err(aws_smithy_xml::decode::XmlDecodeError::custom(format!(
"invalid root, expected PublishResponse got {:?}",
start_el
)));
}
if let Some(mut result_tag) = decoder.next_tag() {
let start_el = result_tag.start_el();
if !(start_el.matches("PublishResult")) {
return Err(aws_smithy_xml::decode::XmlDecodeError::custom(format!(
"invalid result, expected PublishResult got {:?}",
start_el
)));
}
while let Some(mut tag) = result_tag.next_tag() {
match tag.start_el() {
s if s.matches("MessageId") => {
let var_56 =
Some(
Result::<std::string::String, aws_smithy_xml::decode::XmlDecodeError>::Ok(
aws_smithy_xml::decode::try_data(&mut tag)?.as_ref()
.into()
)
?
)
;
builder = builder.set_message_id(var_56);
}
,
s if s.matches("SequenceNumber") => {
let var_57 =
Some(
Result::<std::string::String, aws_smithy_xml::decode::XmlDecodeError>::Ok(
aws_smithy_xml::decode::try_data(&mut tag)?.as_ref()
.into()
)
?
)
;
builder = builder.set_sequence_number(var_57);
}
,
_ => {}
}
}
} else {
return Err(aws_smithy_xml::decode::XmlDecodeError::custom(
"expected PublishResult tag",
));
};
Ok(builder)
}
#[allow(unused_mut)]
pub fn deser_structure_crate_error_batch_entry_ids_not_distinct_exception_xml_err(
inp: &[u8],
mut builder: crate::error::batch_entry_ids_not_distinct_exception::Builder,
) -> Result<
crate::error::batch_entry_ids_not_distinct_exception::Builder,
aws_smithy_xml::decode::XmlDecodeError,
> {
if inp.is_empty() {
return Ok(builder);
}
let mut document = aws_smithy_xml::decode::Document::try_from(inp)?;
#[allow(unused_mut)]
let mut error_decoder = crate::rest_xml_wrapped_errors::error_scope(&mut document)?;
while let Some(mut tag) = error_decoder.next_tag() {
match tag.start_el() {
s if s.matches("message") => {
let var_58 =
Some(
Result::<std::string::String, aws_smithy_xml::decode::XmlDecodeError>::Ok(
aws_smithy_xml::decode::try_data(&mut tag)?.as_ref()
.into()
)
?
)
;
builder = builder.set_message(var_58);
}
,
_ => {}
}
}
Ok(builder)
}
#[allow(unused_mut)]
pub fn deser_structure_crate_error_batch_request_too_long_exception_xml_err(
inp: &[u8],
mut builder: crate::error::batch_request_too_long_exception::Builder,
) -> Result<
crate::error::batch_request_too_long_exception::Builder,
aws_smithy_xml::decode::XmlDecodeError,
> {
if inp.is_empty() {
return Ok(builder);
}
let mut document = aws_smithy_xml::decode::Document::try_from(inp)?;
#[allow(unused_mut)]
let mut error_decoder = crate::rest_xml_wrapped_errors::error_scope(&mut document)?;
while let Some(mut tag) = error_decoder.next_tag() {
match tag.start_el() {
s if s.matches("message") => {
let var_59 =
Some(
Result::<std::string::String, aws_smithy_xml::decode::XmlDecodeError>::Ok(
aws_smithy_xml::decode::try_data(&mut tag)?.as_ref()
.into()
)
?
)
;
builder = builder.set_message(var_59);
}
,
_ => {}
}
}
Ok(builder)
}
#[allow(unused_mut)]
pub fn deser_structure_crate_error_empty_batch_request_exception_xml_err(
inp: &[u8],
mut builder: crate::error::empty_batch_request_exception::Builder,
) -> Result<
crate::error::empty_batch_request_exception::Builder,
aws_smithy_xml::decode::XmlDecodeError,
> {
if inp.is_empty() {
return Ok(builder);
}
let mut document = aws_smithy_xml::decode::Document::try_from(inp)?;
#[allow(unused_mut)]
let mut error_decoder = crate::rest_xml_wrapped_errors::error_scope(&mut document)?;
while let Some(mut tag) = error_decoder.next_tag() {
match tag.start_el() {
s if s.matches("message") => {
let var_60 =
Some(
Result::<std::string::String, aws_smithy_xml::decode::XmlDecodeError>::Ok(
aws_smithy_xml::decode::try_data(&mut tag)?.as_ref()
.into()
)
?
)
;
builder = builder.set_message(var_60);
}
,
_ => {}
}
}
Ok(builder)
}
#[allow(unused_mut)]
pub fn deser_structure_crate_error_invalid_batch_entry_id_exception_xml_err(
inp: &[u8],
mut builder: crate::error::invalid_batch_entry_id_exception::Builder,
) -> Result<
crate::error::invalid_batch_entry_id_exception::Builder,
aws_smithy_xml::decode::XmlDecodeError,
> {
if inp.is_empty() {
return Ok(builder);
}
let mut document = aws_smithy_xml::decode::Document::try_from(inp)?;
#[allow(unused_mut)]
let mut error_decoder = crate::rest_xml_wrapped_errors::error_scope(&mut document)?;
while let Some(mut tag) = error_decoder.next_tag() {
match tag.start_el() {
s if s.matches("message") => {
let var_61 =
Some(
Result::<std::string::String, aws_smithy_xml::decode::XmlDecodeError>::Ok(
aws_smithy_xml::decode::try_data(&mut tag)?.as_ref()
.into()
)
?
)
;
builder = builder.set_message(var_61);
}
,
_ => {}
}
}
Ok(builder)
}
#[allow(unused_mut)]
pub fn deser_structure_crate_error_too_many_entries_in_batch_request_exception_xml_err(
inp: &[u8],
mut builder: crate::error::too_many_entries_in_batch_request_exception::Builder,
) -> Result<
crate::error::too_many_entries_in_batch_request_exception::Builder,
aws_smithy_xml::decode::XmlDecodeError,
> {
if inp.is_empty() {
return Ok(builder);
}
let mut document = aws_smithy_xml::decode::Document::try_from(inp)?;
#[allow(unused_mut)]
let mut error_decoder = crate::rest_xml_wrapped_errors::error_scope(&mut document)?;
while let Some(mut tag) = error_decoder.next_tag() {
match tag.start_el() {
s if s.matches("message") => {
let var_62 =
Some(
Result::<std::string::String, aws_smithy_xml::decode::XmlDecodeError>::Ok(
aws_smithy_xml::decode::try_data(&mut tag)?.as_ref()
.into()
)
?
)
;
builder = builder.set_message(var_62);
}
,
_ => {}
}
}
Ok(builder)
}
#[allow(unused_mut)]
pub fn deser_operation_crate_operation_publish_batch(
inp: &[u8],
mut builder: crate::output::publish_batch_output::Builder,
) -> Result<crate::output::publish_batch_output::Builder, aws_smithy_xml::decode::XmlDecodeError> {
let mut doc = aws_smithy_xml::decode::Document::try_from(inp)?;
#[allow(unused_mut)]
let mut decoder = doc.root_element()?;
#[allow(unused_variables)]
let start_el = decoder.start_el();
if !(start_el.matches("PublishBatchResponse")) {
return Err(aws_smithy_xml::decode::XmlDecodeError::custom(format!(
"invalid root, expected PublishBatchResponse got {:?}",
start_el
)));
}
if let Some(mut result_tag) = decoder.next_tag() {
let start_el = result_tag.start_el();
if !(start_el.matches("PublishBatchResult")) {
return Err(aws_smithy_xml::decode::XmlDecodeError::custom(format!(
"invalid result, expected PublishBatchResult got {:?}",
start_el
)));
}
while let Some(mut tag) = result_tag.next_tag() {
match tag.start_el() {
s if s.matches("Successful") => {
let var_63 =
Some(
crate::xml_deser::deser_list_com_amazonaws_sns_publish_batch_result_entry_list(&mut tag)
?
)
;
builder = builder.set_successful(var_63);
}
,
s if s.matches("Failed") => {
let var_64 =
Some(
crate::xml_deser::deser_list_com_amazonaws_sns_batch_result_error_entry_list(&mut tag)
?
)
;
builder = builder.set_failed(var_64);
}
,
_ => {}
}
}
} else {
return Err(aws_smithy_xml::decode::XmlDecodeError::custom(
"expected PublishBatchResult tag",
));
};
Ok(builder)
}
#[allow(unused_mut)]
pub fn deser_operation_crate_operation_subscribe(
inp: &[u8],
mut builder: crate::output::subscribe_output::Builder,
) -> Result<crate::output::subscribe_output::Builder, aws_smithy_xml::decode::XmlDecodeError> {
let mut doc = aws_smithy_xml::decode::Document::try_from(inp)?;
#[allow(unused_mut)]
let mut decoder = doc.root_element()?;
#[allow(unused_variables)]
let start_el = decoder.start_el();
if !(start_el.matches("SubscribeResponse")) {
return Err(aws_smithy_xml::decode::XmlDecodeError::custom(format!(
"invalid root, expected SubscribeResponse got {:?}",
start_el
)));
}
if let Some(mut result_tag) = decoder.next_tag() {
let start_el = result_tag.start_el();
if !(start_el.matches("SubscribeResult")) {
return Err(aws_smithy_xml::decode::XmlDecodeError::custom(format!(
"invalid result, expected SubscribeResult got {:?}",
start_el
)));
}
while let Some(mut tag) = result_tag.next_tag() {
match tag.start_el() {
s if s.matches("SubscriptionArn") => {
let var_65 =
Some(
Result::<std::string::String, aws_smithy_xml::decode::XmlDecodeError>::Ok(
aws_smithy_xml::decode::try_data(&mut tag)?.as_ref()
.into()
)
?
)
;
builder = builder.set_subscription_arn(var_65);
}
,
_ => {}
}
}
} else {
return Err(aws_smithy_xml::decode::XmlDecodeError::custom(
"expected SubscribeResult tag",
));
};
Ok(builder)
}
#[allow(unused_mut)]
pub fn deser_structure_crate_error_verification_exception_xml_err(
inp: &[u8],
mut builder: crate::error::verification_exception::Builder,
) -> Result<crate::error::verification_exception::Builder, aws_smithy_xml::decode::XmlDecodeError> {
if inp.is_empty() {
return Ok(builder);
}
let mut document = aws_smithy_xml::decode::Document::try_from(inp)?;
#[allow(unused_mut)]
let mut error_decoder = crate::rest_xml_wrapped_errors::error_scope(&mut document)?;
while let Some(mut tag) = error_decoder.next_tag() {
match tag.start_el() {
s if s.matches("Status") => {
let var_66 =
Some(
Result::<std::string::String, aws_smithy_xml::decode::XmlDecodeError>::Ok(
aws_smithy_xml::decode::try_data(&mut tag)?.as_ref()
.into()
)
?
)
;
builder = builder.set_status(var_66);
}
,
s if s.matches("Message") => {
let var_67 =
Some(
Result::<std::string::String, aws_smithy_xml::decode::XmlDecodeError>::Ok(
aws_smithy_xml::decode::try_data(&mut tag)?.as_ref()
.into()
)
?
)
;
builder = builder.set_message(var_67);
}
,
_ => {}
}
}
Ok(builder)
}
pub fn deser_map_com_amazonaws_sns_map_string_to_string(
decoder: &mut aws_smithy_xml::decode::ScopedDecoder,
) -> Result<
std::collections::HashMap<std::string::String, std::string::String>,
aws_smithy_xml::decode::XmlDecodeError,
> {
let mut out = std::collections::HashMap::new();
while let Some(mut tag) = decoder.next_tag() {
match tag.start_el() {
s if s.matches("entry") => {
crate::xml_deser::deser_map_com_amazonaws_sns_map_string_to_string_entry(
&mut tag, &mut out,
)?;
}
_ => {}
}
}
Ok(out)
}
pub fn deser_map_com_amazonaws_sns_subscription_attributes_map(
decoder: &mut aws_smithy_xml::decode::ScopedDecoder,
) -> Result<
std::collections::HashMap<std::string::String, std::string::String>,
aws_smithy_xml::decode::XmlDecodeError,
> {
let mut out = std::collections::HashMap::new();
while let Some(mut tag) = decoder.next_tag() {
match tag.start_el() {
s if s.matches("entry") => {
crate::xml_deser::deser_map_com_amazonaws_sns_subscription_attributes_map_entry(
&mut tag, &mut out,
)?;
}
_ => {}
}
}
Ok(out)
}
pub fn deser_map_com_amazonaws_sns_topic_attributes_map(
decoder: &mut aws_smithy_xml::decode::ScopedDecoder,
) -> Result<
std::collections::HashMap<std::string::String, std::string::String>,
aws_smithy_xml::decode::XmlDecodeError,
> {
let mut out = std::collections::HashMap::new();
while let Some(mut tag) = decoder.next_tag() {
match tag.start_el() {
s if s.matches("entry") => {
crate::xml_deser::deser_map_com_amazonaws_sns_topic_attributes_map_entry(
&mut tag, &mut out,
)?;
}
_ => {}
}
}
Ok(out)
}
pub fn deser_list_com_amazonaws_sns_list_of_endpoints(
decoder: &mut aws_smithy_xml::decode::ScopedDecoder,
) -> Result<std::vec::Vec<crate::model::Endpoint>, aws_smithy_xml::decode::XmlDecodeError> {
let mut out = std::vec::Vec::new();
while let Some(mut tag) = decoder.next_tag() {
match tag.start_el() {
s if s.matches("member") => {
out.push(
crate::xml_deser::deser_structure_crate_model_endpoint(&mut tag)
?
);
}
,
_ => {}
}
}
Ok(out)
}
pub fn deser_list_com_amazonaws_sns_phone_number_information_list(
decoder: &mut aws_smithy_xml::decode::ScopedDecoder,
) -> Result<
std::vec::Vec<crate::model::PhoneNumberInformation>,
aws_smithy_xml::decode::XmlDecodeError,
> {
let mut out = std::vec::Vec::new();
while let Some(mut tag) = decoder.next_tag() {
match tag.start_el() {
s if s.matches("member") => {
out.push(
crate::xml_deser::deser_structure_crate_model_phone_number_information(&mut tag)
?
);
}
,
_ => {}
}
}
Ok(out)
}
pub fn deser_list_com_amazonaws_sns_phone_number_list(
decoder: &mut aws_smithy_xml::decode::ScopedDecoder,
) -> Result<std::vec::Vec<std::string::String>, aws_smithy_xml::decode::XmlDecodeError> {
let mut out = std::vec::Vec::new();
while let Some(mut tag) = decoder.next_tag() {
match tag.start_el() {
s if s.matches("member") => {
out.push(
Result::<std::string::String, aws_smithy_xml::decode::XmlDecodeError>::Ok(
aws_smithy_xml::decode::try_data(&mut tag)?.as_ref()
.into()
)
?
);
}
,
_ => {}
}
}
Ok(out)
}
pub fn deser_list_com_amazonaws_sns_list_of_platform_applications(
decoder: &mut aws_smithy_xml::decode::ScopedDecoder,
) -> Result<std::vec::Vec<crate::model::PlatformApplication>, aws_smithy_xml::decode::XmlDecodeError>
{
let mut out = std::vec::Vec::new();
while let Some(mut tag) = decoder.next_tag() {
match tag.start_el() {
s if s.matches("member") => {
out.push(
crate::xml_deser::deser_structure_crate_model_platform_application(&mut tag)
?
);
}
,
_ => {}
}
}
Ok(out)
}
pub fn deser_list_com_amazonaws_sns_sms_sandbox_phone_number_list(
decoder: &mut aws_smithy_xml::decode::ScopedDecoder,
) -> Result<
std::vec::Vec<crate::model::SmsSandboxPhoneNumber>,
aws_smithy_xml::decode::XmlDecodeError,
> {
let mut out = std::vec::Vec::new();
while let Some(mut tag) = decoder.next_tag() {
match tag.start_el() {
s if s.matches("member") => {
out.push(
crate::xml_deser::deser_structure_crate_model_sms_sandbox_phone_number(&mut tag)
?
);
}
,
_ => {}
}
}
Ok(out)
}
pub fn deser_list_com_amazonaws_sns_subscriptions_list(
decoder: &mut aws_smithy_xml::decode::ScopedDecoder,
) -> Result<std::vec::Vec<crate::model::Subscription>, aws_smithy_xml::decode::XmlDecodeError> {
let mut out = std::vec::Vec::new();
while let Some(mut tag) = decoder.next_tag() {
match tag.start_el() {
s if s.matches("member") => {
out.push(
crate::xml_deser::deser_structure_crate_model_subscription(&mut tag)
?
);
}
,
_ => {}
}
}
Ok(out)
}
pub fn deser_list_com_amazonaws_sns_tag_list(
decoder: &mut aws_smithy_xml::decode::ScopedDecoder,
) -> Result<std::vec::Vec<crate::model::Tag>, aws_smithy_xml::decode::XmlDecodeError> {
let mut out = std::vec::Vec::new();
while let Some(mut tag) = decoder.next_tag() {
match tag.start_el() {
s if s.matches("member") => {
out.push(
crate::xml_deser::deser_structure_crate_model_tag(&mut tag)
?
);
}
,
_ => {}
}
}
Ok(out)
}
pub fn deser_list_com_amazonaws_sns_topics_list(
decoder: &mut aws_smithy_xml::decode::ScopedDecoder,
) -> Result<std::vec::Vec<crate::model::Topic>, aws_smithy_xml::decode::XmlDecodeError> {
let mut out = std::vec::Vec::new();
while let Some(mut tag) = decoder.next_tag() {
match tag.start_el() {
s if s.matches("member") => {
out.push(
crate::xml_deser::deser_structure_crate_model_topic(&mut tag)
?
);
}
,
_ => {}
}
}
Ok(out)
}
pub fn deser_list_com_amazonaws_sns_publish_batch_result_entry_list(
decoder: &mut aws_smithy_xml::decode::ScopedDecoder,
) -> Result<
std::vec::Vec<crate::model::PublishBatchResultEntry>,
aws_smithy_xml::decode::XmlDecodeError,
> {
let mut out = std::vec::Vec::new();
while let Some(mut tag) = decoder.next_tag() {
match tag.start_el() {
s if s.matches("member") => {
out.push(
crate::xml_deser::deser_structure_crate_model_publish_batch_result_entry(&mut tag)
?
);
}
,
_ => {}
}
}
Ok(out)
}
pub fn deser_list_com_amazonaws_sns_batch_result_error_entry_list(
decoder: &mut aws_smithy_xml::decode::ScopedDecoder,
) -> Result<
std::vec::Vec<crate::model::BatchResultErrorEntry>,
aws_smithy_xml::decode::XmlDecodeError,
> {
let mut out = std::vec::Vec::new();
while let Some(mut tag) = decoder.next_tag() {
match tag.start_el() {
s if s.matches("member") => {
out.push(
crate::xml_deser::deser_structure_crate_model_batch_result_error_entry(&mut tag)
?
);
}
,
_ => {}
}
}
Ok(out)
}
pub fn deser_map_com_amazonaws_sns_map_string_to_string_entry(
decoder: &mut aws_smithy_xml::decode::ScopedDecoder,
out: &mut std::collections::HashMap<std::string::String, std::string::String>,
) -> Result<(), aws_smithy_xml::decode::XmlDecodeError> {
let mut k: Option<std::string::String> = None;
let mut v: Option<std::string::String> = None;
while let Some(mut tag) = decoder.next_tag() {
match tag.start_el() {
s if s.matches("key") => {
k = Some(
Result::<std::string::String, aws_smithy_xml::decode::XmlDecodeError>::Ok(
aws_smithy_xml::decode::try_data(&mut tag)?.as_ref()
.into()
)
?
)
}
,
s if s.matches("value") => {
v = Some(
Result::<std::string::String, aws_smithy_xml::decode::XmlDecodeError>::Ok(
aws_smithy_xml::decode::try_data(&mut tag)?.as_ref()
.into()
)
?
)
}
,
_ => {}
}
}
let k =
k.ok_or_else(|| aws_smithy_xml::decode::XmlDecodeError::custom("missing key map entry"))?;
let v =
v.ok_or_else(|| aws_smithy_xml::decode::XmlDecodeError::custom("missing value map entry"))?;
out.insert(k, v);
Ok(())
}
pub fn deser_map_com_amazonaws_sns_subscription_attributes_map_entry(
decoder: &mut aws_smithy_xml::decode::ScopedDecoder,
out: &mut std::collections::HashMap<std::string::String, std::string::String>,
) -> Result<(), aws_smithy_xml::decode::XmlDecodeError> {
let mut k: Option<std::string::String> = None;
let mut v: Option<std::string::String> = None;
while let Some(mut tag) = decoder.next_tag() {
match tag.start_el() {
s if s.matches("key") => {
k = Some(
Result::<std::string::String, aws_smithy_xml::decode::XmlDecodeError>::Ok(
aws_smithy_xml::decode::try_data(&mut tag)?.as_ref()
.into()
)
?
)
}
,
s if s.matches("value") => {
v = Some(
Result::<std::string::String, aws_smithy_xml::decode::XmlDecodeError>::Ok(
aws_smithy_xml::decode::try_data(&mut tag)?.as_ref()
.into()
)
?
)
}
,
_ => {}
}
}
let k =
k.ok_or_else(|| aws_smithy_xml::decode::XmlDecodeError::custom("missing key map entry"))?;
let v =
v.ok_or_else(|| aws_smithy_xml::decode::XmlDecodeError::custom("missing value map entry"))?;
out.insert(k, v);
Ok(())
}
pub fn deser_map_com_amazonaws_sns_topic_attributes_map_entry(
decoder: &mut aws_smithy_xml::decode::ScopedDecoder,
out: &mut std::collections::HashMap<std::string::String, std::string::String>,
) -> Result<(), aws_smithy_xml::decode::XmlDecodeError> {
let mut k: Option<std::string::String> = None;
let mut v: Option<std::string::String> = None;
while let Some(mut tag) = decoder.next_tag() {
match tag.start_el() {
s if s.matches("key") => {
k = Some(
Result::<std::string::String, aws_smithy_xml::decode::XmlDecodeError>::Ok(
aws_smithy_xml::decode::try_data(&mut tag)?.as_ref()
.into()
)
?
)
}
,
s if s.matches("value") => {
v = Some(
Result::<std::string::String, aws_smithy_xml::decode::XmlDecodeError>::Ok(
aws_smithy_xml::decode::try_data(&mut tag)?.as_ref()
.into()
)
?
)
}
,
_ => {}
}
}
let k =
k.ok_or_else(|| aws_smithy_xml::decode::XmlDecodeError::custom("missing key map entry"))?;
let v =
v.ok_or_else(|| aws_smithy_xml::decode::XmlDecodeError::custom("missing value map entry"))?;
out.insert(k, v);
Ok(())
}
pub fn deser_structure_crate_model_endpoint(
decoder: &mut aws_smithy_xml::decode::ScopedDecoder,
) -> Result<crate::model::Endpoint, aws_smithy_xml::decode::XmlDecodeError> {
#[allow(unused_mut)]
let mut builder = crate::model::Endpoint::builder();
while let Some(mut tag) = decoder.next_tag() {
match tag.start_el() {
s if s.matches("EndpointArn") => {
let var_68 =
Some(
Result::<std::string::String, aws_smithy_xml::decode::XmlDecodeError>::Ok(
aws_smithy_xml::decode::try_data(&mut tag)?.as_ref()
.into()
)
?
)
;
builder = builder.set_endpoint_arn(var_68);
}
,
s if s.matches("Attributes") => {
let var_69 =
Some(
crate::xml_deser::deser_map_com_amazonaws_sns_map_string_to_string(&mut tag)
?
)
;
builder = builder.set_attributes(var_69);
}
,
_ => {}
}
}
Ok(builder.build())
}
pub fn deser_structure_crate_model_phone_number_information(
decoder: &mut aws_smithy_xml::decode::ScopedDecoder,
) -> Result<crate::model::PhoneNumberInformation, aws_smithy_xml::decode::XmlDecodeError> {
#[allow(unused_mut)]
let mut builder = crate::model::PhoneNumberInformation::builder();
while let Some(mut tag) = decoder.next_tag() {
match tag.start_el() {
s if s.matches("CreatedAt") => {
let var_70 =
Some(
aws_smithy_types::DateTime::from_str(
aws_smithy_xml::decode::try_data(&mut tag)?.as_ref()
, aws_smithy_types::date_time::Format::DateTime
)
.map_err(|_|aws_smithy_xml::decode::XmlDecodeError::custom("expected (timestamp: `com.amazonaws.sns#Timestamp`)"))
?
)
;
builder = builder.set_created_at(var_70);
}
,
s if s.matches("PhoneNumber") => {
let var_71 =
Some(
Result::<std::string::String, aws_smithy_xml::decode::XmlDecodeError>::Ok(
aws_smithy_xml::decode::try_data(&mut tag)?.as_ref()
.into()
)
?
)
;
builder = builder.set_phone_number(var_71);
}
,
s if s.matches("Status") => {
let var_72 =
Some(
Result::<std::string::String, aws_smithy_xml::decode::XmlDecodeError>::Ok(
aws_smithy_xml::decode::try_data(&mut tag)?.as_ref()
.into()
)
?
)
;
builder = builder.set_status(var_72);
}
,
s if s.matches("Iso2CountryCode") => {
let var_73 =
Some(
Result::<std::string::String, aws_smithy_xml::decode::XmlDecodeError>::Ok(
aws_smithy_xml::decode::try_data(&mut tag)?.as_ref()
.into()
)
?
)
;
builder = builder.set_iso2_country_code(var_73);
}
,
s if s.matches("RouteType") => {
let var_74 =
Some(
Result::<crate::model::RouteType, aws_smithy_xml::decode::XmlDecodeError>::Ok(
crate::model::RouteType::from(
aws_smithy_xml::decode::try_data(&mut tag)?.as_ref()
)
)
?
)
;
builder = builder.set_route_type(var_74);
}
,
s if s.matches("NumberCapabilities") => {
let var_75 =
Some(
crate::xml_deser::deser_list_com_amazonaws_sns_number_capability_list(&mut tag)
?
)
;
builder = builder.set_number_capabilities(var_75);
}
,
_ => {}
}
}
Ok(builder.build())
}
pub fn deser_structure_crate_model_platform_application(
decoder: &mut aws_smithy_xml::decode::ScopedDecoder,
) -> Result<crate::model::PlatformApplication, aws_smithy_xml::decode::XmlDecodeError> {
#[allow(unused_mut)]
let mut builder = crate::model::PlatformApplication::builder();
while let Some(mut tag) = decoder.next_tag() {
match tag.start_el() {
s if s.matches("PlatformApplicationArn") => {
let var_76 =
Some(
Result::<std::string::String, aws_smithy_xml::decode::XmlDecodeError>::Ok(
aws_smithy_xml::decode::try_data(&mut tag)?.as_ref()
.into()
)
?
)
;
builder = builder.set_platform_application_arn(var_76);
}
,
s if s.matches("Attributes") => {
let var_77 =
Some(
crate::xml_deser::deser_map_com_amazonaws_sns_map_string_to_string(&mut tag)
?
)
;
builder = builder.set_attributes(var_77);
}
,
_ => {}
}
}
Ok(builder.build())
}
pub fn deser_structure_crate_model_sms_sandbox_phone_number(
decoder: &mut aws_smithy_xml::decode::ScopedDecoder,
) -> Result<crate::model::SmsSandboxPhoneNumber, aws_smithy_xml::decode::XmlDecodeError> {
#[allow(unused_mut)]
let mut builder = crate::model::SmsSandboxPhoneNumber::builder();
while let Some(mut tag) = decoder.next_tag() {
match tag.start_el() {
s if s.matches("PhoneNumber") => {
let var_78 =
Some(
Result::<std::string::String, aws_smithy_xml::decode::XmlDecodeError>::Ok(
aws_smithy_xml::decode::try_data(&mut tag)?.as_ref()
.into()
)
?
)
;
builder = builder.set_phone_number(var_78);
}
,
s if s.matches("Status") => {
let var_79 =
Some(
Result::<crate::model::SmsSandboxPhoneNumberVerificationStatus, aws_smithy_xml::decode::XmlDecodeError>::Ok(
crate::model::SmsSandboxPhoneNumberVerificationStatus::from(
aws_smithy_xml::decode::try_data(&mut tag)?.as_ref()
)
)
?
)
;
builder = builder.set_status(var_79);
}
,
_ => {}
}
}
Ok(builder.build())
}
pub fn deser_structure_crate_model_subscription(
decoder: &mut aws_smithy_xml::decode::ScopedDecoder,
) -> Result<crate::model::Subscription, aws_smithy_xml::decode::XmlDecodeError> {
#[allow(unused_mut)]
let mut builder = crate::model::Subscription::builder();
while let Some(mut tag) = decoder.next_tag() {
match tag.start_el() {
s if s.matches("SubscriptionArn") => {
let var_80 =
Some(
Result::<std::string::String, aws_smithy_xml::decode::XmlDecodeError>::Ok(
aws_smithy_xml::decode::try_data(&mut tag)?.as_ref()
.into()
)
?
)
;
builder = builder.set_subscription_arn(var_80);
}
,
s if s.matches("Owner") => {
let var_81 =
Some(
Result::<std::string::String, aws_smithy_xml::decode::XmlDecodeError>::Ok(
aws_smithy_xml::decode::try_data(&mut tag)?.as_ref()
.into()
)
?
)
;
builder = builder.set_owner(var_81);
}
,
s if s.matches("Protocol") => {
let var_82 =
Some(
Result::<std::string::String, aws_smithy_xml::decode::XmlDecodeError>::Ok(
aws_smithy_xml::decode::try_data(&mut tag)?.as_ref()
.into()
)
?
)
;
builder = builder.set_protocol(var_82);
}
,
s if s.matches("Endpoint") => {
let var_83 =
Some(
Result::<std::string::String, aws_smithy_xml::decode::XmlDecodeError>::Ok(
aws_smithy_xml::decode::try_data(&mut tag)?.as_ref()
.into()
)
?
)
;
builder = builder.set_endpoint(var_83);
}
,
s if s.matches("TopicArn") => {
let var_84 =
Some(
Result::<std::string::String, aws_smithy_xml::decode::XmlDecodeError>::Ok(
aws_smithy_xml::decode::try_data(&mut tag)?.as_ref()
.into()
)
?
)
;
builder = builder.set_topic_arn(var_84);
}
,
_ => {}
}
}
Ok(builder.build())
}
pub fn deser_structure_crate_model_tag(
decoder: &mut aws_smithy_xml::decode::ScopedDecoder,
) -> Result<crate::model::Tag, aws_smithy_xml::decode::XmlDecodeError> {
#[allow(unused_mut)]
let mut builder = crate::model::Tag::builder();
while let Some(mut tag) = decoder.next_tag() {
match tag.start_el() {
s if s.matches("Key") => {
let var_85 =
Some(
Result::<std::string::String, aws_smithy_xml::decode::XmlDecodeError>::Ok(
aws_smithy_xml::decode::try_data(&mut tag)?.as_ref()
.into()
)
?
)
;
builder = builder.set_key(var_85);
}
,
s if s.matches("Value") => {
let var_86 =
Some(
Result::<std::string::String, aws_smithy_xml::decode::XmlDecodeError>::Ok(
aws_smithy_xml::decode::try_data(&mut tag)?.as_ref()
.into()
)
?
)
;
builder = builder.set_value(var_86);
}
,
_ => {}
}
}
Ok(builder.build())
}
pub fn deser_structure_crate_model_topic(
decoder: &mut aws_smithy_xml::decode::ScopedDecoder,
) -> Result<crate::model::Topic, aws_smithy_xml::decode::XmlDecodeError> {
#[allow(unused_mut)]
let mut builder = crate::model::Topic::builder();
while let Some(mut tag) = decoder.next_tag() {
match tag.start_el() {
s if s.matches("TopicArn") => {
let var_87 =
Some(
Result::<std::string::String, aws_smithy_xml::decode::XmlDecodeError>::Ok(
aws_smithy_xml::decode::try_data(&mut tag)?.as_ref()
.into()
)
?
)
;
builder = builder.set_topic_arn(var_87);
}
,
_ => {}
}
}
Ok(builder.build())
}
pub fn deser_structure_crate_model_publish_batch_result_entry(
decoder: &mut aws_smithy_xml::decode::ScopedDecoder,
) -> Result<crate::model::PublishBatchResultEntry, aws_smithy_xml::decode::XmlDecodeError> {
#[allow(unused_mut)]
let mut builder = crate::model::PublishBatchResultEntry::builder();
while let Some(mut tag) = decoder.next_tag() {
match tag.start_el() {
s if s.matches("Id") => {
let var_88 =
Some(
Result::<std::string::String, aws_smithy_xml::decode::XmlDecodeError>::Ok(
aws_smithy_xml::decode::try_data(&mut tag)?.as_ref()
.into()
)
?
)
;
builder = builder.set_id(var_88);
}
,
s if s.matches("MessageId") => {
let var_89 =
Some(
Result::<std::string::String, aws_smithy_xml::decode::XmlDecodeError>::Ok(
aws_smithy_xml::decode::try_data(&mut tag)?.as_ref()
.into()
)
?
)
;
builder = builder.set_message_id(var_89);
}
,
s if s.matches("SequenceNumber") => {
let var_90 =
Some(
Result::<std::string::String, aws_smithy_xml::decode::XmlDecodeError>::Ok(
aws_smithy_xml::decode::try_data(&mut tag)?.as_ref()
.into()
)
?
)
;
builder = builder.set_sequence_number(var_90);
}
,
_ => {}
}
}
Ok(builder.build())
}
pub fn deser_structure_crate_model_batch_result_error_entry(
decoder: &mut aws_smithy_xml::decode::ScopedDecoder,
) -> Result<crate::model::BatchResultErrorEntry, aws_smithy_xml::decode::XmlDecodeError> {
#[allow(unused_mut)]
let mut builder = crate::model::BatchResultErrorEntry::builder();
while let Some(mut tag) = decoder.next_tag() {
match tag.start_el() {
s if s.matches("Id") => {
let var_91 =
Some(
Result::<std::string::String, aws_smithy_xml::decode::XmlDecodeError>::Ok(
aws_smithy_xml::decode::try_data(&mut tag)?.as_ref()
.into()
)
?
)
;
builder = builder.set_id(var_91);
}
,
s if s.matches("Code") => {
let var_92 =
Some(
Result::<std::string::String, aws_smithy_xml::decode::XmlDecodeError>::Ok(
aws_smithy_xml::decode::try_data(&mut tag)?.as_ref()
.into()
)
?
)
;
builder = builder.set_code(var_92);
}
,
s if s.matches("Message") => {
let var_93 =
Some(
Result::<std::string::String, aws_smithy_xml::decode::XmlDecodeError>::Ok(
aws_smithy_xml::decode::try_data(&mut tag)?.as_ref()
.into()
)
?
)
;
builder = builder.set_message(var_93);
}
,
s if s.matches("SenderFault") => {
let var_94 =
Some(
{
<bool as aws_smithy_types::primitive::Parse>::parse_smithy_primitive(
aws_smithy_xml::decode::try_data(&mut tag)?.as_ref()
)
.map_err(|_|aws_smithy_xml::decode::XmlDecodeError::custom("expected (boolean: `com.amazonaws.sns#boolean`)"))
}
?
)
;
builder = builder.set_sender_fault(var_94);
}
,
_ => {}
}
}
Ok(builder.build())
}
pub fn deser_list_com_amazonaws_sns_number_capability_list(
decoder: &mut aws_smithy_xml::decode::ScopedDecoder,
) -> Result<std::vec::Vec<crate::model::NumberCapability>, aws_smithy_xml::decode::XmlDecodeError> {
let mut out = std::vec::Vec::new();
while let Some(mut tag) = decoder.next_tag() {
match tag.start_el() {
s if s.matches("member") => {
out.push(
Result::<crate::model::NumberCapability, aws_smithy_xml::decode::XmlDecodeError>::Ok(
crate::model::NumberCapability::from(
aws_smithy_xml::decode::try_data(&mut tag)?.as_ref()
)
)
?
);
}
,
_ => {}
}
}
Ok(out)
}