AWS SDK

AWS SDK

rev. 32b1b3c3761061baed26023be3219639e42d7d12

Files changed:

tmp-codegen-diff/aws-sdk/sdk/ec2/src/operation/reset_image_attribute/_reset_image_attribute_output.rs

@@ -1,1 +80,111 @@
    3      3   
#[non_exhaustive]
    4      4   
#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::fmt::Debug)]
    5      5   
pub struct ResetImageAttributeOutput {
    6      6   
    _request_id: Option<String>,
    7      7   
}
    8      8   
static RESETIMAGEATTRIBUTEOUTPUT_SCHEMA_ID: ::aws_smithy_schema::ShapeId = ::aws_smithy_schema::ShapeId::from_static(
    9      9   
    "com.amazonaws.ec2.synthetic#ResetImageAttributeOutput",
   10     10   
    "com.amazonaws.ec2.synthetic",
   11     11   
    "ResetImageAttributeOutput",
   12     12   
);
   13         -
static RESETIMAGEATTRIBUTEOUTPUT_SCHEMA: ::aws_smithy_schema::Schema =
   14         -
    ::aws_smithy_schema::Schema::new_struct(RESETIMAGEATTRIBUTEOUTPUT_SCHEMA_ID, ::aws_smithy_schema::ShapeType::Structure, &[]);
          13  +
static RESETIMAGEATTRIBUTEOUTPUT_MEMBER__REQUEST_ID: ::aws_smithy_schema::Schema = ::aws_smithy_schema::Schema::new_member(
          14  +
    ::aws_smithy_schema::ShapeId::from_static("synthetic#request_id", "synthetic", "request_id"),
          15  +
    ::aws_smithy_schema::ShapeType::String,
          16  +
    "request_id",
          17  +
    0,
          18  +
)
          19  +
.with_http_header("x-amzn-requestid");
          20  +
static RESETIMAGEATTRIBUTEOUTPUT_SCHEMA: ::aws_smithy_schema::Schema = ::aws_smithy_schema::Schema::new_struct(
          21  +
    RESETIMAGEATTRIBUTEOUTPUT_SCHEMA_ID,
          22  +
    ::aws_smithy_schema::ShapeType::Structure,
          23  +
    &[&RESETIMAGEATTRIBUTEOUTPUT_MEMBER__REQUEST_ID],
          24  +
);
   15     25   
impl ResetImageAttributeOutput {
   16     26   
    /// The schema for this shape.
   17     27   
    pub const SCHEMA: &'static ::aws_smithy_schema::Schema = &RESETIMAGEATTRIBUTEOUTPUT_SCHEMA;
   18     28   
}
   19     29   
impl ::aws_smithy_schema::serde::SerializableStruct for ResetImageAttributeOutput {
   20     30   
    #[allow(unused_variables, clippy::diverging_sub_expression)]
   21     31   
    fn serialize_members(
   22     32   
        &self,
   23     33   
        ser: &mut dyn ::aws_smithy_schema::serde::ShapeSerializer,
   24     34   
    ) -> ::std::result::Result<(), ::aws_smithy_schema::serde::SerdeError> {
   25     35   
        Ok(())
   26     36   
    }
   27     37   
}
   28     38   
impl ResetImageAttributeOutput {
   29     39   
    /// Deserializes this structure from a [`ShapeDeserializer`].
   30         -
    pub fn deserialize<D: ::aws_smithy_schema::serde::ShapeDeserializer>(
   31         -
        deserializer: &mut D,
          40  +
    pub fn deserialize(
          41  +
        deserializer: &mut dyn ::aws_smithy_schema::serde::ShapeDeserializer,
   32     42   
    ) -> ::std::result::Result<Self, ::aws_smithy_schema::serde::SerdeError> {
   33     43   
        #[allow(unused_variables, unused_mut)]
   34     44   
        let mut builder = Self::builder();
   35     45   
        #[allow(
   36     46   
            unused_variables,
   37     47   
            unreachable_code,
   38     48   
            clippy::single_match,
   39     49   
            clippy::match_single_binding,
   40     50   
            clippy::diverging_sub_expression
   41     51   
        )]
   42         -
        deserializer.read_struct(&RESETIMAGEATTRIBUTEOUTPUT_SCHEMA, (), |_, member, deser| {
          52  +
        deserializer.read_struct(&RESETIMAGEATTRIBUTEOUTPUT_SCHEMA, &mut |member, deser| {
   43     53   
            match member.member_index() {
          54  +
                Some(0) => {
          55  +
                    builder._request_id = Some(deser.read_string(member)?);
          56  +
                }
   44     57   
                _ => {}
   45     58   
            }
   46     59   
            Ok(())
   47     60   
        })?;
   48     61   
        Ok(builder.build())
   49     62   
    }
   50     63   
}
          64  +
impl ResetImageAttributeOutput {
          65  +
    /// Deserializes this structure from a body deserializer and HTTP response headers.
          66  +
    /// Header-bound members are read directly from headers, avoiding runtime
          67  +
    /// member iteration overhead. Body members are read via the deserializer.
          68  +
    pub fn deserialize_with_response(
          69  +
        _deserializer: &mut dyn ::aws_smithy_schema::serde::ShapeDeserializer,
          70  +
        headers: &::aws_smithy_runtime_api::http::Headers,
          71  +
        _status: u16,
          72  +
        _body: &[u8],
          73  +
    ) -> ::std::result::Result<Self, ::aws_smithy_schema::serde::SerdeError> {
          74  +
        #[allow(unused_variables, unused_mut)]
          75  +
        let mut builder = Self::builder();
          76  +
        if let Some(val) = headers.get("x-amzn-requestid") {
          77  +
            builder._request_id = Some(val.to_string());
          78  +
        }
          79  +
        Ok(builder.build())
          80  +
    }
          81  +
}
   51     82   
impl ::aws_types::request_id::RequestId for ResetImageAttributeOutput {
   52     83   
    fn request_id(&self) -> Option<&str> {
   53     84   
        self._request_id.as_deref()
   54     85   
    }
   55     86   
}
   56     87   
impl ResetImageAttributeOutput {
   57     88   
    /// Creates a new builder-style object to manufacture [`ResetImageAttributeOutput`](crate::operation::reset_image_attribute::ResetImageAttributeOutput).
   58     89   
    pub fn builder() -> crate::operation::reset_image_attribute::builders::ResetImageAttributeOutputBuilder {
   59     90   
        crate::operation::reset_image_attribute::builders::ResetImageAttributeOutputBuilder::default()
   60     91   
    }

tmp-codegen-diff/aws-sdk/sdk/ec2/src/operation/reset_instance_attribute.rs

@@ -1,1 +40,44 @@
    1      1   
// Code generated by software.amazon.smithy.rust.codegen.smithy-rs. DO NOT EDIT.
    2      2   
/// Orchestration and serialization glue logic for `ResetInstanceAttribute`.
    3      3   
#[derive(::std::clone::Clone, ::std::default::Default, ::std::fmt::Debug)]
    4      4   
#[non_exhaustive]
    5      5   
pub struct ResetInstanceAttribute;
    6      6   
impl ResetInstanceAttribute {
    7      7   
    /// Creates a new `ResetInstanceAttribute`
    8      8   
    pub fn new() -> Self {
    9      9   
        Self
   10     10   
    }
          11  +
    /// The schema for this operation's input shape.
          12  +
    pub const INPUT_SCHEMA: &'static ::aws_smithy_schema::Schema = crate::operation::reset_instance_attribute::ResetInstanceAttributeInput::SCHEMA;
          13  +
    /// The schema for this operation's output shape.
          14  +
    pub const OUTPUT_SCHEMA: &'static ::aws_smithy_schema::Schema = crate::operation::reset_instance_attribute::ResetInstanceAttributeOutput::SCHEMA;
   11     15   
    pub(crate) async fn orchestrate(
   12     16   
        runtime_plugins: &::aws_smithy_runtime_api::client::runtime_plugin::RuntimePlugins,
   13     17   
        input: crate::operation::reset_instance_attribute::ResetInstanceAttributeInput,
   14     18   
    ) -> ::std::result::Result<
   15     19   
        crate::operation::reset_instance_attribute::ResetInstanceAttributeOutput,
   16     20   
        ::aws_smithy_runtime_api::client::result::SdkError<
   17     21   
            crate::operation::reset_instance_attribute::ResetInstanceAttributeError,
   18     22   
            ::aws_smithy_runtime_api::client::orchestrator::HttpResponse,
   19     23   
        >,
   20     24   
    > {
@@ -118,122 +180,185 @@
  138    142   
                crate::operation::reset_instance_attribute::ResetInstanceAttributeError,
  139    143   
            >::new());
  140    144   
  141    145   
        ::std::borrow::Cow::Owned(rcb)
  142    146   
    }
  143    147   
}
  144    148   
  145    149   
#[derive(Debug)]
  146    150   
struct ResetInstanceAttributeResponseDeserializer;
  147    151   
impl ::aws_smithy_runtime_api::client::ser_de::DeserializeResponse for ResetInstanceAttributeResponseDeserializer {
  148         -
    fn deserialize_nonstreaming(
         152  +
    fn deserialize_nonstreaming_with_config(
  149    153   
        &self,
  150    154   
        response: &::aws_smithy_runtime_api::client::orchestrator::HttpResponse,
         155  +
        _cfg: &::aws_smithy_types::config_bag::ConfigBag,
  151    156   
    ) -> ::aws_smithy_runtime_api::client::interceptors::context::OutputOrError {
  152    157   
        let (success, status) = (response.status().is_success(), response.status().as_u16());
  153    158   
        let headers = response.headers();
  154    159   
        let body = response.body().bytes().expect("body loaded");
  155    160   
        #[allow(unused_mut)]
  156    161   
        let mut force_error = false;
  157    162   
        ::tracing::debug!(request_id = ?::aws_types::request_id::RequestId::request_id(response));
  158    163   
        let parse_result = if !success && status != 200 || force_error {
  159    164   
            crate::protocol_serde::shape_reset_instance_attribute::de_reset_instance_attribute_http_error(status, headers, body)
  160    165   
        } else {

tmp-codegen-diff/aws-sdk/sdk/ec2/src/operation/reset_instance_attribute/_reset_instance_attribute_input.rs

@@ -13,13 +163,175 @@
   33     33   
    "com.amazonaws.ec2.synthetic",
   34     34   
    "ResetInstanceAttributeInput",
   35     35   
);
   36     36   
static RESETINSTANCEATTRIBUTEINPUT_MEMBER_DRY_RUN: ::aws_smithy_schema::Schema = ::aws_smithy_schema::Schema::new_member(
   37     37   
    ::aws_smithy_schema::ShapeId::from_static(
   38     38   
        "com.amazonaws.ec2.synthetic#ResetInstanceAttributeInput$DryRun",
   39     39   
        "com.amazonaws.ec2.synthetic",
   40     40   
        "ResetInstanceAttributeInput",
   41     41   
    ),
   42     42   
    ::aws_smithy_schema::ShapeType::Boolean,
   43         -
    "dry_run",
          43  +
    "DryRun",
   44     44   
    0,
   45     45   
)
   46     46   
.with_xml_name("dryRun");
   47     47   
static RESETINSTANCEATTRIBUTEINPUT_MEMBER_INSTANCE_ID: ::aws_smithy_schema::Schema = ::aws_smithy_schema::Schema::new_member(
   48     48   
    ::aws_smithy_schema::ShapeId::from_static(
   49     49   
        "com.amazonaws.ec2.synthetic#ResetInstanceAttributeInput$InstanceId",
   50     50   
        "com.amazonaws.ec2.synthetic",
   51     51   
        "ResetInstanceAttributeInput",
   52     52   
    ),
   53     53   
    ::aws_smithy_schema::ShapeType::String,
   54         -
    "instance_id",
          54  +
    "InstanceId",
   55     55   
    1,
   56     56   
)
   57     57   
.with_xml_name("instanceId");
   58     58   
static RESETINSTANCEATTRIBUTEINPUT_MEMBER_ATTRIBUTE: ::aws_smithy_schema::Schema = ::aws_smithy_schema::Schema::new_member(
   59     59   
    ::aws_smithy_schema::ShapeId::from_static(
   60     60   
        "com.amazonaws.ec2.synthetic#ResetInstanceAttributeInput$Attribute",
   61     61   
        "com.amazonaws.ec2.synthetic",
   62     62   
        "ResetInstanceAttributeInput",
   63     63   
    ),
   64     64   
    ::aws_smithy_schema::ShapeType::String,
   65         -
    "attribute",
          65  +
    "Attribute",
   66     66   
    2,
   67     67   
)
   68     68   
.with_xml_name("attribute");
   69     69   
static RESETINSTANCEATTRIBUTEINPUT_SCHEMA: ::aws_smithy_schema::Schema = ::aws_smithy_schema::Schema::new_struct(
   70     70   
    RESETINSTANCEATTRIBUTEINPUT_SCHEMA_ID,
   71     71   
    ::aws_smithy_schema::ShapeType::Structure,
   72     72   
    &[
   73     73   
        &RESETINSTANCEATTRIBUTEINPUT_MEMBER_DRY_RUN,
   74     74   
        &RESETINSTANCEATTRIBUTEINPUT_MEMBER_INSTANCE_ID,
   75     75   
        &RESETINSTANCEATTRIBUTEINPUT_MEMBER_ATTRIBUTE,
   76     76   
    ],
   77     77   
);
   78     78   
impl ResetInstanceAttributeInput {
   79     79   
    /// The schema for this shape.
   80     80   
    pub const SCHEMA: &'static ::aws_smithy_schema::Schema = &RESETINSTANCEATTRIBUTEINPUT_SCHEMA;
   81     81   
}
   82     82   
impl ::aws_smithy_schema::serde::SerializableStruct for ResetInstanceAttributeInput {
   83     83   
    #[allow(unused_variables, clippy::diverging_sub_expression)]
   84     84   
    fn serialize_members(
   85     85   
        &self,
   86     86   
        ser: &mut dyn ::aws_smithy_schema::serde::ShapeSerializer,
   87     87   
    ) -> ::std::result::Result<(), ::aws_smithy_schema::serde::SerdeError> {
   88     88   
        if let Some(ref val) = self.dry_run {
   89     89   
            ser.write_boolean(&RESETINSTANCEATTRIBUTEINPUT_MEMBER_DRY_RUN, *val)?;
   90     90   
        }
   91     91   
        if let Some(ref val) = self.instance_id {
   92     92   
            ser.write_string(&RESETINSTANCEATTRIBUTEINPUT_MEMBER_INSTANCE_ID, val)?;
   93     93   
        }
   94     94   
        if let Some(ref val) = self.attribute {
   95     95   
            ser.write_string(&RESETINSTANCEATTRIBUTEINPUT_MEMBER_ATTRIBUTE, val.as_str())?;
   96     96   
        }
   97     97   
        Ok(())
   98     98   
    }
   99     99   
}
  100    100   
impl ResetInstanceAttributeInput {
  101    101   
    /// Deserializes this structure from a [`ShapeDeserializer`].
  102         -
    pub fn deserialize<D: ::aws_smithy_schema::serde::ShapeDeserializer>(
  103         -
        deserializer: &mut D,
         102  +
    pub fn deserialize(
         103  +
        deserializer: &mut dyn ::aws_smithy_schema::serde::ShapeDeserializer,
  104    104   
    ) -> ::std::result::Result<Self, ::aws_smithy_schema::serde::SerdeError> {
  105    105   
        #[allow(unused_variables, unused_mut)]
  106    106   
        let mut builder = Self::builder();
  107    107   
        #[allow(
  108    108   
            unused_variables,
  109    109   
            unreachable_code,
  110    110   
            clippy::single_match,
  111    111   
            clippy::match_single_binding,
  112    112   
            clippy::diverging_sub_expression
  113    113   
        )]
  114         -
        deserializer.read_struct(&RESETINSTANCEATTRIBUTEINPUT_SCHEMA, (), |_, member, deser| {
         114  +
        deserializer.read_struct(&RESETINSTANCEATTRIBUTEINPUT_SCHEMA, &mut |member, deser| {
  115    115   
            match member.member_index() {
  116    116   
                Some(0) => {
  117    117   
                    builder.dry_run = Some(deser.read_boolean(member)?);
  118    118   
                }
  119    119   
                Some(1) => {
  120    120   
                    builder.instance_id = Some(deser.read_string(member)?);
  121    121   
                }
  122    122   
                Some(2) => {
  123    123   
                    builder.attribute = Some(crate::types::InstanceAttributeName::from(deser.read_string(member)?.as_str()));
  124    124   
                }
  125    125   
                _ => {}
  126    126   
            }
  127    127   
            Ok(())
  128    128   
        })?;
         129  +
        builder.instance_id = builder.instance_id.or(Some(String::new()));
  129    130   
        builder
  130    131   
            .build()
  131    132   
            .map_err(|e| aws_smithy_schema::serde::SerdeError::Custom { message: e.to_string() })
  132    133   
    }
  133    134   
}
         135  +
impl ResetInstanceAttributeInput {
         136  +
    /// Deserializes this structure from a body deserializer and HTTP response.
         137  +
    pub fn deserialize_with_response(
         138  +
        deserializer: &mut dyn ::aws_smithy_schema::serde::ShapeDeserializer,
         139  +
        _headers: &::aws_smithy_runtime_api::http::Headers,
         140  +
        _status: u16,
         141  +
        _body: &[u8],
         142  +
    ) -> ::std::result::Result<Self, ::aws_smithy_schema::serde::SerdeError> {
         143  +
        Self::deserialize(deserializer)
         144  +
    }
         145  +
}
  134    146   
impl ResetInstanceAttributeInput {
  135    147   
    /// Creates a new builder-style object to manufacture [`ResetInstanceAttributeInput`](crate::operation::reset_instance_attribute::ResetInstanceAttributeInput).
  136    148   
    pub fn builder() -> crate::operation::reset_instance_attribute::builders::ResetInstanceAttributeInputBuilder {
  137    149   
        crate::operation::reset_instance_attribute::builders::ResetInstanceAttributeInputBuilder::default()
  138    150   
    }
  139    151   
}
  140    152   
  141    153   
/// A builder for [`ResetInstanceAttributeInput`](crate::operation::reset_instance_attribute::ResetInstanceAttributeInput).
  142    154   
#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::default::Default, ::std::fmt::Debug)]
  143    155   
#[non_exhaustive]

tmp-codegen-diff/aws-sdk/sdk/ec2/src/operation/reset_instance_attribute/_reset_instance_attribute_output.rs

@@ -1,1 +80,111 @@
    3      3   
#[non_exhaustive]
    4      4   
#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::fmt::Debug)]
    5      5   
pub struct ResetInstanceAttributeOutput {
    6      6   
    _request_id: Option<String>,
    7      7   
}
    8      8   
static RESETINSTANCEATTRIBUTEOUTPUT_SCHEMA_ID: ::aws_smithy_schema::ShapeId = ::aws_smithy_schema::ShapeId::from_static(
    9      9   
    "com.amazonaws.ec2.synthetic#ResetInstanceAttributeOutput",
   10     10   
    "com.amazonaws.ec2.synthetic",
   11     11   
    "ResetInstanceAttributeOutput",
   12     12   
);
   13         -
static RESETINSTANCEATTRIBUTEOUTPUT_SCHEMA: ::aws_smithy_schema::Schema =
   14         -
    ::aws_smithy_schema::Schema::new_struct(RESETINSTANCEATTRIBUTEOUTPUT_SCHEMA_ID, ::aws_smithy_schema::ShapeType::Structure, &[]);
          13  +
static RESETINSTANCEATTRIBUTEOUTPUT_MEMBER__REQUEST_ID: ::aws_smithy_schema::Schema = ::aws_smithy_schema::Schema::new_member(
          14  +
    ::aws_smithy_schema::ShapeId::from_static("synthetic#request_id", "synthetic", "request_id"),
          15  +
    ::aws_smithy_schema::ShapeType::String,
          16  +
    "request_id",
          17  +
    0,
          18  +
)
          19  +
.with_http_header("x-amzn-requestid");
          20  +
static RESETINSTANCEATTRIBUTEOUTPUT_SCHEMA: ::aws_smithy_schema::Schema = ::aws_smithy_schema::Schema::new_struct(
          21  +
    RESETINSTANCEATTRIBUTEOUTPUT_SCHEMA_ID,
          22  +
    ::aws_smithy_schema::ShapeType::Structure,
          23  +
    &[&RESETINSTANCEATTRIBUTEOUTPUT_MEMBER__REQUEST_ID],
          24  +
);
   15     25   
impl ResetInstanceAttributeOutput {
   16     26   
    /// The schema for this shape.
   17     27   
    pub const SCHEMA: &'static ::aws_smithy_schema::Schema = &RESETINSTANCEATTRIBUTEOUTPUT_SCHEMA;
   18     28   
}
   19     29   
impl ::aws_smithy_schema::serde::SerializableStruct for ResetInstanceAttributeOutput {
   20     30   
    #[allow(unused_variables, clippy::diverging_sub_expression)]
   21     31   
    fn serialize_members(
   22     32   
        &self,
   23     33   
        ser: &mut dyn ::aws_smithy_schema::serde::ShapeSerializer,
   24     34   
    ) -> ::std::result::Result<(), ::aws_smithy_schema::serde::SerdeError> {
   25     35   
        Ok(())
   26     36   
    }
   27     37   
}
   28     38   
impl ResetInstanceAttributeOutput {
   29     39   
    /// Deserializes this structure from a [`ShapeDeserializer`].
   30         -
    pub fn deserialize<D: ::aws_smithy_schema::serde::ShapeDeserializer>(
   31         -
        deserializer: &mut D,
          40  +
    pub fn deserialize(
          41  +
        deserializer: &mut dyn ::aws_smithy_schema::serde::ShapeDeserializer,
   32     42   
    ) -> ::std::result::Result<Self, ::aws_smithy_schema::serde::SerdeError> {
   33     43   
        #[allow(unused_variables, unused_mut)]
   34     44   
        let mut builder = Self::builder();
   35     45   
        #[allow(
   36     46   
            unused_variables,
   37     47   
            unreachable_code,
   38     48   
            clippy::single_match,
   39     49   
            clippy::match_single_binding,
   40     50   
            clippy::diverging_sub_expression
   41     51   
        )]
   42         -
        deserializer.read_struct(&RESETINSTANCEATTRIBUTEOUTPUT_SCHEMA, (), |_, member, deser| {
          52  +
        deserializer.read_struct(&RESETINSTANCEATTRIBUTEOUTPUT_SCHEMA, &mut |member, deser| {
   43     53   
            match member.member_index() {
          54  +
                Some(0) => {
          55  +
                    builder._request_id = Some(deser.read_string(member)?);
          56  +
                }
   44     57   
                _ => {}
   45     58   
            }
   46     59   
            Ok(())
   47     60   
        })?;
   48     61   
        Ok(builder.build())
   49     62   
    }
   50     63   
}
          64  +
impl ResetInstanceAttributeOutput {
          65  +
    /// Deserializes this structure from a body deserializer and HTTP response headers.
          66  +
    /// Header-bound members are read directly from headers, avoiding runtime
          67  +
    /// member iteration overhead. Body members are read via the deserializer.
          68  +
    pub fn deserialize_with_response(
          69  +
        _deserializer: &mut dyn ::aws_smithy_schema::serde::ShapeDeserializer,
          70  +
        headers: &::aws_smithy_runtime_api::http::Headers,
          71  +
        _status: u16,
          72  +
        _body: &[u8],
          73  +
    ) -> ::std::result::Result<Self, ::aws_smithy_schema::serde::SerdeError> {
          74  +
        #[allow(unused_variables, unused_mut)]
          75  +
        let mut builder = Self::builder();
          76  +
        if let Some(val) = headers.get("x-amzn-requestid") {
          77  +
            builder._request_id = Some(val.to_string());
          78  +
        }
          79  +
        Ok(builder.build())
          80  +
    }
          81  +
}
   51     82   
impl ::aws_types::request_id::RequestId for ResetInstanceAttributeOutput {
   52     83   
    fn request_id(&self) -> Option<&str> {
   53     84   
        self._request_id.as_deref()
   54     85   
    }
   55     86   
}
   56     87   
impl ResetInstanceAttributeOutput {
   57     88   
    /// Creates a new builder-style object to manufacture [`ResetInstanceAttributeOutput`](crate::operation::reset_instance_attribute::ResetInstanceAttributeOutput).
   58     89   
    pub fn builder() -> crate::operation::reset_instance_attribute::builders::ResetInstanceAttributeOutputBuilder {
   59     90   
        crate::operation::reset_instance_attribute::builders::ResetInstanceAttributeOutputBuilder::default()
   60     91   
    }

tmp-codegen-diff/aws-sdk/sdk/ec2/src/operation/reset_network_interface_attribute.rs

@@ -1,1 +40,46 @@
    1      1   
// Code generated by software.amazon.smithy.rust.codegen.smithy-rs. DO NOT EDIT.
    2      2   
/// Orchestration and serialization glue logic for `ResetNetworkInterfaceAttribute`.
    3      3   
#[derive(::std::clone::Clone, ::std::default::Default, ::std::fmt::Debug)]
    4      4   
#[non_exhaustive]
    5      5   
pub struct ResetNetworkInterfaceAttribute;
    6      6   
impl ResetNetworkInterfaceAttribute {
    7      7   
    /// Creates a new `ResetNetworkInterfaceAttribute`
    8      8   
    pub fn new() -> Self {
    9      9   
        Self
   10     10   
    }
          11  +
    /// The schema for this operation's input shape.
          12  +
    pub const INPUT_SCHEMA: &'static ::aws_smithy_schema::Schema =
          13  +
        crate::operation::reset_network_interface_attribute::ResetNetworkInterfaceAttributeInput::SCHEMA;
          14  +
    /// The schema for this operation's output shape.
          15  +
    pub const OUTPUT_SCHEMA: &'static ::aws_smithy_schema::Schema =
          16  +
        crate::operation::reset_network_interface_attribute::ResetNetworkInterfaceAttributeOutput::SCHEMA;
   11     17   
    pub(crate) async fn orchestrate(
   12     18   
        runtime_plugins: &::aws_smithy_runtime_api::client::runtime_plugin::RuntimePlugins,
   13     19   
        input: crate::operation::reset_network_interface_attribute::ResetNetworkInterfaceAttributeInput,
   14     20   
    ) -> ::std::result::Result<
   15     21   
        crate::operation::reset_network_interface_attribute::ResetNetworkInterfaceAttributeOutput,
   16     22   
        ::aws_smithy_runtime_api::client::result::SdkError<
   17     23   
            crate::operation::reset_network_interface_attribute::ResetNetworkInterfaceAttributeError,
   18     24   
            ::aws_smithy_runtime_api::client::orchestrator::HttpResponse,
   19     25   
        >,
   20     26   
    > {
@@ -124,130 +186,193 @@
  144    150   
                crate::operation::reset_network_interface_attribute::ResetNetworkInterfaceAttributeError,
  145    151   
            >::new());
  146    152   
  147    153   
        ::std::borrow::Cow::Owned(rcb)
  148    154   
    }
  149    155   
}
  150    156   
  151    157   
#[derive(Debug)]
  152    158   
struct ResetNetworkInterfaceAttributeResponseDeserializer;
  153    159   
impl ::aws_smithy_runtime_api::client::ser_de::DeserializeResponse for ResetNetworkInterfaceAttributeResponseDeserializer {
  154         -
    fn deserialize_nonstreaming(
         160  +
    fn deserialize_nonstreaming_with_config(
  155    161   
        &self,
  156    162   
        response: &::aws_smithy_runtime_api::client::orchestrator::HttpResponse,
         163  +
        _cfg: &::aws_smithy_types::config_bag::ConfigBag,
  157    164   
    ) -> ::aws_smithy_runtime_api::client::interceptors::context::OutputOrError {
  158    165   
        let (success, status) = (response.status().is_success(), response.status().as_u16());
  159    166   
        let headers = response.headers();
  160    167   
        let body = response.body().bytes().expect("body loaded");
  161    168   
        #[allow(unused_mut)]
  162    169   
        let mut force_error = false;
  163    170   
        ::tracing::debug!(request_id = ?::aws_types::request_id::RequestId::request_id(response));
  164    171   
        let parse_result = if !success && status != 200 || force_error {
  165    172   
            crate::protocol_serde::shape_reset_network_interface_attribute::de_reset_network_interface_attribute_http_error(status, headers, body)
  166    173   
        } else {

tmp-codegen-diff/aws-sdk/sdk/ec2/src/operation/reset_network_interface_attribute/_reset_network_interface_attribute_input.rs

@@ -10,10 +160,172 @@
   30     30   
    "com.amazonaws.ec2.synthetic",
   31     31   
    "ResetNetworkInterfaceAttributeInput",
   32     32   
);
   33     33   
static RESETNETWORKINTERFACEATTRIBUTEINPUT_MEMBER_DRY_RUN: ::aws_smithy_schema::Schema = ::aws_smithy_schema::Schema::new_member(
   34     34   
    ::aws_smithy_schema::ShapeId::from_static(
   35     35   
        "com.amazonaws.ec2.synthetic#ResetNetworkInterfaceAttributeInput$DryRun",
   36     36   
        "com.amazonaws.ec2.synthetic",
   37     37   
        "ResetNetworkInterfaceAttributeInput",
   38     38   
    ),
   39     39   
    ::aws_smithy_schema::ShapeType::Boolean,
   40         -
    "dry_run",
          40  +
    "DryRun",
   41     41   
    0,
   42     42   
)
   43     43   
.with_xml_name("dryRun");
   44     44   
static RESETNETWORKINTERFACEATTRIBUTEINPUT_MEMBER_NETWORK_INTERFACE_ID: ::aws_smithy_schema::Schema = ::aws_smithy_schema::Schema::new_member(
   45     45   
    ::aws_smithy_schema::ShapeId::from_static(
   46     46   
        "com.amazonaws.ec2.synthetic#ResetNetworkInterfaceAttributeInput$NetworkInterfaceId",
   47     47   
        "com.amazonaws.ec2.synthetic",
   48     48   
        "ResetNetworkInterfaceAttributeInput",
   49     49   
    ),
   50     50   
    ::aws_smithy_schema::ShapeType::String,
   51         -
    "network_interface_id",
          51  +
    "NetworkInterfaceId",
   52     52   
    1,
   53     53   
)
   54     54   
.with_xml_name("networkInterfaceId");
   55     55   
static RESETNETWORKINTERFACEATTRIBUTEINPUT_MEMBER_SOURCE_DEST_CHECK: ::aws_smithy_schema::Schema = ::aws_smithy_schema::Schema::new_member(
   56     56   
    ::aws_smithy_schema::ShapeId::from_static(
   57     57   
        "com.amazonaws.ec2.synthetic#ResetNetworkInterfaceAttributeInput$SourceDestCheck",
   58     58   
        "com.amazonaws.ec2.synthetic",
   59     59   
        "ResetNetworkInterfaceAttributeInput",
   60     60   
    ),
   61     61   
    ::aws_smithy_schema::ShapeType::String,
   62         -
    "source_dest_check",
          62  +
    "SourceDestCheck",
   63     63   
    2,
   64     64   
)
   65     65   
.with_xml_name("sourceDestCheck");
   66     66   
static RESETNETWORKINTERFACEATTRIBUTEINPUT_SCHEMA: ::aws_smithy_schema::Schema = ::aws_smithy_schema::Schema::new_struct(
   67     67   
    RESETNETWORKINTERFACEATTRIBUTEINPUT_SCHEMA_ID,
   68     68   
    ::aws_smithy_schema::ShapeType::Structure,
   69     69   
    &[
   70     70   
        &RESETNETWORKINTERFACEATTRIBUTEINPUT_MEMBER_DRY_RUN,
   71     71   
        &RESETNETWORKINTERFACEATTRIBUTEINPUT_MEMBER_NETWORK_INTERFACE_ID,
   72     72   
        &RESETNETWORKINTERFACEATTRIBUTEINPUT_MEMBER_SOURCE_DEST_CHECK,
   73     73   
    ],
   74     74   
);
   75     75   
impl ResetNetworkInterfaceAttributeInput {
   76     76   
    /// The schema for this shape.
   77     77   
    pub const SCHEMA: &'static ::aws_smithy_schema::Schema = &RESETNETWORKINTERFACEATTRIBUTEINPUT_SCHEMA;
   78     78   
}
   79     79   
impl ::aws_smithy_schema::serde::SerializableStruct for ResetNetworkInterfaceAttributeInput {
   80     80   
    #[allow(unused_variables, clippy::diverging_sub_expression)]
   81     81   
    fn serialize_members(
   82     82   
        &self,
   83     83   
        ser: &mut dyn ::aws_smithy_schema::serde::ShapeSerializer,
   84     84   
    ) -> ::std::result::Result<(), ::aws_smithy_schema::serde::SerdeError> {
   85     85   
        if let Some(ref val) = self.dry_run {
   86     86   
            ser.write_boolean(&RESETNETWORKINTERFACEATTRIBUTEINPUT_MEMBER_DRY_RUN, *val)?;
   87     87   
        }
   88     88   
        if let Some(ref val) = self.network_interface_id {
   89     89   
            ser.write_string(&RESETNETWORKINTERFACEATTRIBUTEINPUT_MEMBER_NETWORK_INTERFACE_ID, val)?;
   90     90   
        }
   91     91   
        if let Some(ref val) = self.source_dest_check {
   92     92   
            ser.write_string(&RESETNETWORKINTERFACEATTRIBUTEINPUT_MEMBER_SOURCE_DEST_CHECK, val)?;
   93     93   
        }
   94     94   
        Ok(())
   95     95   
    }
   96     96   
}
   97     97   
impl ResetNetworkInterfaceAttributeInput {
   98     98   
    /// Deserializes this structure from a [`ShapeDeserializer`].
   99         -
    pub fn deserialize<D: ::aws_smithy_schema::serde::ShapeDeserializer>(
  100         -
        deserializer: &mut D,
          99  +
    pub fn deserialize(
         100  +
        deserializer: &mut dyn ::aws_smithy_schema::serde::ShapeDeserializer,
  101    101   
    ) -> ::std::result::Result<Self, ::aws_smithy_schema::serde::SerdeError> {
  102    102   
        #[allow(unused_variables, unused_mut)]
  103    103   
        let mut builder = Self::builder();
  104    104   
        #[allow(
  105    105   
            unused_variables,
  106    106   
            unreachable_code,
  107    107   
            clippy::single_match,
  108    108   
            clippy::match_single_binding,
  109    109   
            clippy::diverging_sub_expression
  110    110   
        )]
  111         -
        deserializer.read_struct(&RESETNETWORKINTERFACEATTRIBUTEINPUT_SCHEMA, (), |_, member, deser| {
         111  +
        deserializer.read_struct(&RESETNETWORKINTERFACEATTRIBUTEINPUT_SCHEMA, &mut |member, deser| {
  112    112   
            match member.member_index() {
  113    113   
                Some(0) => {
  114    114   
                    builder.dry_run = Some(deser.read_boolean(member)?);
  115    115   
                }
  116    116   
                Some(1) => {
  117    117   
                    builder.network_interface_id = Some(deser.read_string(member)?);
  118    118   
                }
  119    119   
                Some(2) => {
  120    120   
                    builder.source_dest_check = Some(deser.read_string(member)?);
  121    121   
                }
  122    122   
                _ => {}
  123    123   
            }
  124    124   
            Ok(())
  125    125   
        })?;
         126  +
        builder.network_interface_id = builder.network_interface_id.or(Some(String::new()));
  126    127   
        builder
  127    128   
            .build()
  128    129   
            .map_err(|e| aws_smithy_schema::serde::SerdeError::Custom { message: e.to_string() })
  129    130   
    }
  130    131   
}
         132  +
impl ResetNetworkInterfaceAttributeInput {
         133  +
    /// Deserializes this structure from a body deserializer and HTTP response.
         134  +
    pub fn deserialize_with_response(
         135  +
        deserializer: &mut dyn ::aws_smithy_schema::serde::ShapeDeserializer,
         136  +
        _headers: &::aws_smithy_runtime_api::http::Headers,
         137  +
        _status: u16,
         138  +
        _body: &[u8],
         139  +
    ) -> ::std::result::Result<Self, ::aws_smithy_schema::serde::SerdeError> {
         140  +
        Self::deserialize(deserializer)
         141  +
    }
         142  +
}
  131    143   
impl ResetNetworkInterfaceAttributeInput {
  132    144   
    /// Creates a new builder-style object to manufacture [`ResetNetworkInterfaceAttributeInput`](crate::operation::reset_network_interface_attribute::ResetNetworkInterfaceAttributeInput).
  133    145   
    pub fn builder() -> crate::operation::reset_network_interface_attribute::builders::ResetNetworkInterfaceAttributeInputBuilder {
  134    146   
        crate::operation::reset_network_interface_attribute::builders::ResetNetworkInterfaceAttributeInputBuilder::default()
  135    147   
    }
  136    148   
}
  137    149   
  138    150   
/// A builder for [`ResetNetworkInterfaceAttributeInput`](crate::operation::reset_network_interface_attribute::ResetNetworkInterfaceAttributeInput).
  139    151   
#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::default::Default, ::std::fmt::Debug)]
  140    152   
#[non_exhaustive]

tmp-codegen-diff/aws-sdk/sdk/ec2/src/operation/reset_network_interface_attribute/_reset_network_interface_attribute_output.rs

@@ -1,1 +83,111 @@
    3      3   
#[non_exhaustive]
    4      4   
#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::fmt::Debug)]
    5      5   
pub struct ResetNetworkInterfaceAttributeOutput {
    6      6   
    _request_id: Option<String>,
    7      7   
}
    8      8   
static RESETNETWORKINTERFACEATTRIBUTEOUTPUT_SCHEMA_ID: ::aws_smithy_schema::ShapeId = ::aws_smithy_schema::ShapeId::from_static(
    9      9   
    "com.amazonaws.ec2.synthetic#ResetNetworkInterfaceAttributeOutput",
   10     10   
    "com.amazonaws.ec2.synthetic",
   11     11   
    "ResetNetworkInterfaceAttributeOutput",
   12     12   
);
          13  +
static RESETNETWORKINTERFACEATTRIBUTEOUTPUT_MEMBER__REQUEST_ID: ::aws_smithy_schema::Schema = ::aws_smithy_schema::Schema::new_member(
          14  +
    ::aws_smithy_schema::ShapeId::from_static("synthetic#request_id", "synthetic", "request_id"),
          15  +
    ::aws_smithy_schema::ShapeType::String,
          16  +
    "request_id",
          17  +
    0,
          18  +
)
          19  +
.with_http_header("x-amzn-requestid");
   13     20   
static RESETNETWORKINTERFACEATTRIBUTEOUTPUT_SCHEMA: ::aws_smithy_schema::Schema = ::aws_smithy_schema::Schema::new_struct(
   14     21   
    RESETNETWORKINTERFACEATTRIBUTEOUTPUT_SCHEMA_ID,
   15     22   
    ::aws_smithy_schema::ShapeType::Structure,
   16         -
    &[],
          23  +
    &[&RESETNETWORKINTERFACEATTRIBUTEOUTPUT_MEMBER__REQUEST_ID],
   17     24   
);
   18     25   
impl ResetNetworkInterfaceAttributeOutput {
   19     26   
    /// The schema for this shape.
   20     27   
    pub const SCHEMA: &'static ::aws_smithy_schema::Schema = &RESETNETWORKINTERFACEATTRIBUTEOUTPUT_SCHEMA;
   21     28   
}
   22     29   
impl ::aws_smithy_schema::serde::SerializableStruct for ResetNetworkInterfaceAttributeOutput {
   23     30   
    #[allow(unused_variables, clippy::diverging_sub_expression)]
   24     31   
    fn serialize_members(
   25     32   
        &self,
   26     33   
        ser: &mut dyn ::aws_smithy_schema::serde::ShapeSerializer,
   27     34   
    ) -> ::std::result::Result<(), ::aws_smithy_schema::serde::SerdeError> {
   28     35   
        Ok(())
   29     36   
    }
   30     37   
}
   31     38   
impl ResetNetworkInterfaceAttributeOutput {
   32     39   
    /// Deserializes this structure from a [`ShapeDeserializer`].
   33         -
    pub fn deserialize<D: ::aws_smithy_schema::serde::ShapeDeserializer>(
   34         -
        deserializer: &mut D,
          40  +
    pub fn deserialize(
          41  +
        deserializer: &mut dyn ::aws_smithy_schema::serde::ShapeDeserializer,
   35     42   
    ) -> ::std::result::Result<Self, ::aws_smithy_schema::serde::SerdeError> {
   36     43   
        #[allow(unused_variables, unused_mut)]
   37     44   
        let mut builder = Self::builder();
   38     45   
        #[allow(
   39     46   
            unused_variables,
   40     47   
            unreachable_code,
   41     48   
            clippy::single_match,
   42     49   
            clippy::match_single_binding,
   43     50   
            clippy::diverging_sub_expression
   44     51   
        )]
   45         -
        deserializer.read_struct(&RESETNETWORKINTERFACEATTRIBUTEOUTPUT_SCHEMA, (), |_, member, deser| {
          52  +
        deserializer.read_struct(&RESETNETWORKINTERFACEATTRIBUTEOUTPUT_SCHEMA, &mut |member, deser| {
   46     53   
            match member.member_index() {
          54  +
                Some(0) => {
          55  +
                    builder._request_id = Some(deser.read_string(member)?);
          56  +
                }
   47     57   
                _ => {}
   48     58   
            }
   49     59   
            Ok(())
   50     60   
        })?;
   51     61   
        Ok(builder.build())
   52     62   
    }
   53     63   
}
          64  +
impl ResetNetworkInterfaceAttributeOutput {
          65  +
    /// Deserializes this structure from a body deserializer and HTTP response headers.
          66  +
    /// Header-bound members are read directly from headers, avoiding runtime
          67  +
    /// member iteration overhead. Body members are read via the deserializer.
          68  +
    pub fn deserialize_with_response(
          69  +
        _deserializer: &mut dyn ::aws_smithy_schema::serde::ShapeDeserializer,
          70  +
        headers: &::aws_smithy_runtime_api::http::Headers,
          71  +
        _status: u16,
          72  +
        _body: &[u8],
          73  +
    ) -> ::std::result::Result<Self, ::aws_smithy_schema::serde::SerdeError> {
          74  +
        #[allow(unused_variables, unused_mut)]
          75  +
        let mut builder = Self::builder();
          76  +
        if let Some(val) = headers.get("x-amzn-requestid") {
          77  +
            builder._request_id = Some(val.to_string());
          78  +
        }
          79  +
        Ok(builder.build())
          80  +
    }
          81  +
}
   54     82   
impl ::aws_types::request_id::RequestId for ResetNetworkInterfaceAttributeOutput {
   55     83   
    fn request_id(&self) -> Option<&str> {
   56     84   
        self._request_id.as_deref()
   57     85   
    }
   58     86   
}
   59     87   
impl ResetNetworkInterfaceAttributeOutput {
   60     88   
    /// Creates a new builder-style object to manufacture [`ResetNetworkInterfaceAttributeOutput`](crate::operation::reset_network_interface_attribute::ResetNetworkInterfaceAttributeOutput).
   61     89   
    pub fn builder() -> crate::operation::reset_network_interface_attribute::builders::ResetNetworkInterfaceAttributeOutputBuilder {
   62     90   
        crate::operation::reset_network_interface_attribute::builders::ResetNetworkInterfaceAttributeOutputBuilder::default()
   63     91   
    }

tmp-codegen-diff/aws-sdk/sdk/ec2/src/operation/reset_snapshot_attribute.rs

@@ -1,1 +40,44 @@
    1      1   
// Code generated by software.amazon.smithy.rust.codegen.smithy-rs. DO NOT EDIT.
    2      2   
/// Orchestration and serialization glue logic for `ResetSnapshotAttribute`.
    3      3   
#[derive(::std::clone::Clone, ::std::default::Default, ::std::fmt::Debug)]
    4      4   
#[non_exhaustive]
    5      5   
pub struct ResetSnapshotAttribute;
    6      6   
impl ResetSnapshotAttribute {
    7      7   
    /// Creates a new `ResetSnapshotAttribute`
    8      8   
    pub fn new() -> Self {
    9      9   
        Self
   10     10   
    }
          11  +
    /// The schema for this operation's input shape.
          12  +
    pub const INPUT_SCHEMA: &'static ::aws_smithy_schema::Schema = crate::operation::reset_snapshot_attribute::ResetSnapshotAttributeInput::SCHEMA;
          13  +
    /// The schema for this operation's output shape.
          14  +
    pub const OUTPUT_SCHEMA: &'static ::aws_smithy_schema::Schema = crate::operation::reset_snapshot_attribute::ResetSnapshotAttributeOutput::SCHEMA;
   11     15   
    pub(crate) async fn orchestrate(
   12     16   
        runtime_plugins: &::aws_smithy_runtime_api::client::runtime_plugin::RuntimePlugins,
   13     17   
        input: crate::operation::reset_snapshot_attribute::ResetSnapshotAttributeInput,
   14     18   
    ) -> ::std::result::Result<
   15     19   
        crate::operation::reset_snapshot_attribute::ResetSnapshotAttributeOutput,
   16     20   
        ::aws_smithy_runtime_api::client::result::SdkError<
   17     21   
            crate::operation::reset_snapshot_attribute::ResetSnapshotAttributeError,
   18     22   
            ::aws_smithy_runtime_api::client::orchestrator::HttpResponse,
   19     23   
        >,
   20     24   
    > {
@@ -118,122 +180,185 @@
  138    142   
                crate::operation::reset_snapshot_attribute::ResetSnapshotAttributeError,
  139    143   
            >::new());
  140    144   
  141    145   
        ::std::borrow::Cow::Owned(rcb)
  142    146   
    }
  143    147   
}
  144    148   
  145    149   
#[derive(Debug)]
  146    150   
struct ResetSnapshotAttributeResponseDeserializer;
  147    151   
impl ::aws_smithy_runtime_api::client::ser_de::DeserializeResponse for ResetSnapshotAttributeResponseDeserializer {
  148         -
    fn deserialize_nonstreaming(
         152  +
    fn deserialize_nonstreaming_with_config(
  149    153   
        &self,
  150    154   
        response: &::aws_smithy_runtime_api::client::orchestrator::HttpResponse,
         155  +
        _cfg: &::aws_smithy_types::config_bag::ConfigBag,
  151    156   
    ) -> ::aws_smithy_runtime_api::client::interceptors::context::OutputOrError {
  152    157   
        let (success, status) = (response.status().is_success(), response.status().as_u16());
  153    158   
        let headers = response.headers();
  154    159   
        let body = response.body().bytes().expect("body loaded");
  155    160   
        #[allow(unused_mut)]
  156    161   
        let mut force_error = false;
  157    162   
        ::tracing::debug!(request_id = ?::aws_types::request_id::RequestId::request_id(response));
  158    163   
        let parse_result = if !success && status != 200 || force_error {
  159    164   
            crate::protocol_serde::shape_reset_snapshot_attribute::de_reset_snapshot_attribute_http_error(status, headers, body)
  160    165   
        } else {

tmp-codegen-diff/aws-sdk/sdk/ec2/src/operation/reset_snapshot_attribute/_reset_snapshot_attribute_input.rs

@@ -9,9 +157,169 @@
   29     29   
    "com.amazonaws.ec2.synthetic",
   30     30   
    "ResetSnapshotAttributeInput",
   31     31   
);
   32     32   
static RESETSNAPSHOTATTRIBUTEINPUT_MEMBER_ATTRIBUTE: ::aws_smithy_schema::Schema = ::aws_smithy_schema::Schema::new_member(
   33     33   
    ::aws_smithy_schema::ShapeId::from_static(
   34     34   
        "com.amazonaws.ec2.synthetic#ResetSnapshotAttributeInput$Attribute",
   35     35   
        "com.amazonaws.ec2.synthetic",
   36     36   
        "ResetSnapshotAttributeInput",
   37     37   
    ),
   38     38   
    ::aws_smithy_schema::ShapeType::String,
   39         -
    "attribute",
          39  +
    "Attribute",
   40     40   
    0,
   41     41   
);
   42     42   
static RESETSNAPSHOTATTRIBUTEINPUT_MEMBER_SNAPSHOT_ID: ::aws_smithy_schema::Schema = ::aws_smithy_schema::Schema::new_member(
   43     43   
    ::aws_smithy_schema::ShapeId::from_static(
   44     44   
        "com.amazonaws.ec2.synthetic#ResetSnapshotAttributeInput$SnapshotId",
   45     45   
        "com.amazonaws.ec2.synthetic",
   46     46   
        "ResetSnapshotAttributeInput",
   47     47   
    ),
   48     48   
    ::aws_smithy_schema::ShapeType::String,
   49         -
    "snapshot_id",
          49  +
    "SnapshotId",
   50     50   
    1,
   51     51   
);
   52     52   
static RESETSNAPSHOTATTRIBUTEINPUT_MEMBER_DRY_RUN: ::aws_smithy_schema::Schema = ::aws_smithy_schema::Schema::new_member(
   53     53   
    ::aws_smithy_schema::ShapeId::from_static(
   54     54   
        "com.amazonaws.ec2.synthetic#ResetSnapshotAttributeInput$DryRun",
   55     55   
        "com.amazonaws.ec2.synthetic",
   56     56   
        "ResetSnapshotAttributeInput",
   57     57   
    ),
   58     58   
    ::aws_smithy_schema::ShapeType::Boolean,
   59         -
    "dry_run",
          59  +
    "DryRun",
   60     60   
    2,
   61     61   
)
   62     62   
.with_xml_name("dryRun");
   63     63   
static RESETSNAPSHOTATTRIBUTEINPUT_SCHEMA: ::aws_smithy_schema::Schema = ::aws_smithy_schema::Schema::new_struct(
   64     64   
    RESETSNAPSHOTATTRIBUTEINPUT_SCHEMA_ID,
   65     65   
    ::aws_smithy_schema::ShapeType::Structure,
   66     66   
    &[
   67     67   
        &RESETSNAPSHOTATTRIBUTEINPUT_MEMBER_ATTRIBUTE,
   68     68   
        &RESETSNAPSHOTATTRIBUTEINPUT_MEMBER_SNAPSHOT_ID,
   69     69   
        &RESETSNAPSHOTATTRIBUTEINPUT_MEMBER_DRY_RUN,
   70     70   
    ],
   71     71   
);
   72     72   
impl ResetSnapshotAttributeInput {
   73     73   
    /// The schema for this shape.
   74     74   
    pub const SCHEMA: &'static ::aws_smithy_schema::Schema = &RESETSNAPSHOTATTRIBUTEINPUT_SCHEMA;
   75     75   
}
   76     76   
impl ::aws_smithy_schema::serde::SerializableStruct for ResetSnapshotAttributeInput {
   77     77   
    #[allow(unused_variables, clippy::diverging_sub_expression)]
   78     78   
    fn serialize_members(
   79     79   
        &self,
   80     80   
        ser: &mut dyn ::aws_smithy_schema::serde::ShapeSerializer,
   81     81   
    ) -> ::std::result::Result<(), ::aws_smithy_schema::serde::SerdeError> {
   82     82   
        if let Some(ref val) = self.attribute {
   83     83   
            ser.write_string(&RESETSNAPSHOTATTRIBUTEINPUT_MEMBER_ATTRIBUTE, val.as_str())?;
   84     84   
        }
   85     85   
        if let Some(ref val) = self.snapshot_id {
   86     86   
            ser.write_string(&RESETSNAPSHOTATTRIBUTEINPUT_MEMBER_SNAPSHOT_ID, val)?;
   87     87   
        }
   88     88   
        if let Some(ref val) = self.dry_run {
   89     89   
            ser.write_boolean(&RESETSNAPSHOTATTRIBUTEINPUT_MEMBER_DRY_RUN, *val)?;
   90     90   
        }
   91     91   
        Ok(())
   92     92   
    }
   93     93   
}
   94     94   
impl ResetSnapshotAttributeInput {
   95     95   
    /// Deserializes this structure from a [`ShapeDeserializer`].
   96         -
    pub fn deserialize<D: ::aws_smithy_schema::serde::ShapeDeserializer>(
   97         -
        deserializer: &mut D,
          96  +
    pub fn deserialize(
          97  +
        deserializer: &mut dyn ::aws_smithy_schema::serde::ShapeDeserializer,
   98     98   
    ) -> ::std::result::Result<Self, ::aws_smithy_schema::serde::SerdeError> {
   99     99   
        #[allow(unused_variables, unused_mut)]
  100    100   
        let mut builder = Self::builder();
  101    101   
        #[allow(
  102    102   
            unused_variables,
  103    103   
            unreachable_code,
  104    104   
            clippy::single_match,
  105    105   
            clippy::match_single_binding,
  106    106   
            clippy::diverging_sub_expression
  107    107   
        )]
  108         -
        deserializer.read_struct(&RESETSNAPSHOTATTRIBUTEINPUT_SCHEMA, (), |_, member, deser| {
         108  +
        deserializer.read_struct(&RESETSNAPSHOTATTRIBUTEINPUT_SCHEMA, &mut |member, deser| {
  109    109   
            match member.member_index() {
  110    110   
                Some(0) => {
  111    111   
                    builder.attribute = Some(crate::types::SnapshotAttributeName::from(deser.read_string(member)?.as_str()));
  112    112   
                }
  113    113   
                Some(1) => {
  114    114   
                    builder.snapshot_id = Some(deser.read_string(member)?);
  115    115   
                }
  116    116   
                Some(2) => {
  117    117   
                    builder.dry_run = Some(deser.read_boolean(member)?);
  118    118   
                }
  119    119   
                _ => {}
  120    120   
            }
  121    121   
            Ok(())
  122    122   
        })?;
         123  +
        builder.snapshot_id = builder.snapshot_id.or(Some(String::new()));
  123    124   
        builder
  124    125   
            .build()
  125    126   
            .map_err(|e| aws_smithy_schema::serde::SerdeError::Custom { message: e.to_string() })
  126    127   
    }
  127    128   
}
         129  +
impl ResetSnapshotAttributeInput {
         130  +
    /// Deserializes this structure from a body deserializer and HTTP response.
         131  +
    pub fn deserialize_with_response(
         132  +
        deserializer: &mut dyn ::aws_smithy_schema::serde::ShapeDeserializer,
         133  +
        _headers: &::aws_smithy_runtime_api::http::Headers,
         134  +
        _status: u16,
         135  +
        _body: &[u8],
         136  +
    ) -> ::std::result::Result<Self, ::aws_smithy_schema::serde::SerdeError> {
         137  +
        Self::deserialize(deserializer)
         138  +
    }
         139  +
}
  128    140   
impl ResetSnapshotAttributeInput {
  129    141   
    /// Creates a new builder-style object to manufacture [`ResetSnapshotAttributeInput`](crate::operation::reset_snapshot_attribute::ResetSnapshotAttributeInput).
  130    142   
    pub fn builder() -> crate::operation::reset_snapshot_attribute::builders::ResetSnapshotAttributeInputBuilder {
  131    143   
        crate::operation::reset_snapshot_attribute::builders::ResetSnapshotAttributeInputBuilder::default()
  132    144   
    }
  133    145   
}
  134    146   
  135    147   
/// A builder for [`ResetSnapshotAttributeInput`](crate::operation::reset_snapshot_attribute::ResetSnapshotAttributeInput).
  136    148   
#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::default::Default, ::std::fmt::Debug)]
  137    149   
#[non_exhaustive]

tmp-codegen-diff/aws-sdk/sdk/ec2/src/operation/reset_snapshot_attribute/_reset_snapshot_attribute_output.rs

@@ -1,1 +80,111 @@
    3      3   
#[non_exhaustive]
    4      4   
#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::fmt::Debug)]
    5      5   
pub struct ResetSnapshotAttributeOutput {
    6      6   
    _request_id: Option<String>,
    7      7   
}
    8      8   
static RESETSNAPSHOTATTRIBUTEOUTPUT_SCHEMA_ID: ::aws_smithy_schema::ShapeId = ::aws_smithy_schema::ShapeId::from_static(
    9      9   
    "com.amazonaws.ec2.synthetic#ResetSnapshotAttributeOutput",
   10     10   
    "com.amazonaws.ec2.synthetic",
   11     11   
    "ResetSnapshotAttributeOutput",
   12     12   
);
   13         -
static RESETSNAPSHOTATTRIBUTEOUTPUT_SCHEMA: ::aws_smithy_schema::Schema =
   14         -
    ::aws_smithy_schema::Schema::new_struct(RESETSNAPSHOTATTRIBUTEOUTPUT_SCHEMA_ID, ::aws_smithy_schema::ShapeType::Structure, &[]);
          13  +
static RESETSNAPSHOTATTRIBUTEOUTPUT_MEMBER__REQUEST_ID: ::aws_smithy_schema::Schema = ::aws_smithy_schema::Schema::new_member(
          14  +
    ::aws_smithy_schema::ShapeId::from_static("synthetic#request_id", "synthetic", "request_id"),
          15  +
    ::aws_smithy_schema::ShapeType::String,
          16  +
    "request_id",
          17  +
    0,
          18  +
)
          19  +
.with_http_header("x-amzn-requestid");
          20  +
static RESETSNAPSHOTATTRIBUTEOUTPUT_SCHEMA: ::aws_smithy_schema::Schema = ::aws_smithy_schema::Schema::new_struct(
          21  +
    RESETSNAPSHOTATTRIBUTEOUTPUT_SCHEMA_ID,
          22  +
    ::aws_smithy_schema::ShapeType::Structure,
          23  +
    &[&RESETSNAPSHOTATTRIBUTEOUTPUT_MEMBER__REQUEST_ID],
          24  +
);
   15     25   
impl ResetSnapshotAttributeOutput {
   16     26   
    /// The schema for this shape.
   17     27   
    pub const SCHEMA: &'static ::aws_smithy_schema::Schema = &RESETSNAPSHOTATTRIBUTEOUTPUT_SCHEMA;
   18     28   
}
   19     29   
impl ::aws_smithy_schema::serde::SerializableStruct for ResetSnapshotAttributeOutput {
   20     30   
    #[allow(unused_variables, clippy::diverging_sub_expression)]
   21     31   
    fn serialize_members(
   22     32   
        &self,
   23     33   
        ser: &mut dyn ::aws_smithy_schema::serde::ShapeSerializer,
   24     34   
    ) -> ::std::result::Result<(), ::aws_smithy_schema::serde::SerdeError> {
   25     35   
        Ok(())
   26     36   
    }
   27     37   
}
   28     38   
impl ResetSnapshotAttributeOutput {
   29     39   
    /// Deserializes this structure from a [`ShapeDeserializer`].
   30         -
    pub fn deserialize<D: ::aws_smithy_schema::serde::ShapeDeserializer>(
   31         -
        deserializer: &mut D,
          40  +
    pub fn deserialize(
          41  +
        deserializer: &mut dyn ::aws_smithy_schema::serde::ShapeDeserializer,
   32     42   
    ) -> ::std::result::Result<Self, ::aws_smithy_schema::serde::SerdeError> {
   33     43   
        #[allow(unused_variables, unused_mut)]
   34     44   
        let mut builder = Self::builder();
   35     45   
        #[allow(
   36     46   
            unused_variables,
   37     47   
            unreachable_code,
   38     48   
            clippy::single_match,
   39     49   
            clippy::match_single_binding,
   40     50   
            clippy::diverging_sub_expression
   41     51   
        )]
   42         -
        deserializer.read_struct(&RESETSNAPSHOTATTRIBUTEOUTPUT_SCHEMA, (), |_, member, deser| {
          52  +
        deserializer.read_struct(&RESETSNAPSHOTATTRIBUTEOUTPUT_SCHEMA, &mut |member, deser| {
   43     53   
            match member.member_index() {
          54  +
                Some(0) => {
          55  +
                    builder._request_id = Some(deser.read_string(member)?);
          56  +
                }
   44     57   
                _ => {}
   45     58   
            }
   46     59   
            Ok(())
   47     60   
        })?;
   48     61   
        Ok(builder.build())
   49     62   
    }
   50     63   
}
          64  +
impl ResetSnapshotAttributeOutput {
          65  +
    /// Deserializes this structure from a body deserializer and HTTP response headers.
          66  +
    /// Header-bound members are read directly from headers, avoiding runtime
          67  +
    /// member iteration overhead. Body members are read via the deserializer.
          68  +
    pub fn deserialize_with_response(
          69  +
        _deserializer: &mut dyn ::aws_smithy_schema::serde::ShapeDeserializer,
          70  +
        headers: &::aws_smithy_runtime_api::http::Headers,
          71  +
        _status: u16,
          72  +
        _body: &[u8],
          73  +
    ) -> ::std::result::Result<Self, ::aws_smithy_schema::serde::SerdeError> {
          74  +
        #[allow(unused_variables, unused_mut)]
          75  +
        let mut builder = Self::builder();
          76  +
        if let Some(val) = headers.get("x-amzn-requestid") {
          77  +
            builder._request_id = Some(val.to_string());
          78  +
        }
          79  +
        Ok(builder.build())
          80  +
    }
          81  +
}
   51     82   
impl ::aws_types::request_id::RequestId for ResetSnapshotAttributeOutput {
   52     83   
    fn request_id(&self) -> Option<&str> {
   53     84   
        self._request_id.as_deref()
   54     85   
    }
   55     86   
}
   56     87   
impl ResetSnapshotAttributeOutput {
   57     88   
    /// Creates a new builder-style object to manufacture [`ResetSnapshotAttributeOutput`](crate::operation::reset_snapshot_attribute::ResetSnapshotAttributeOutput).
   58     89   
    pub fn builder() -> crate::operation::reset_snapshot_attribute::builders::ResetSnapshotAttributeOutputBuilder {
   59     90   
        crate::operation::reset_snapshot_attribute::builders::ResetSnapshotAttributeOutputBuilder::default()
   60     91   
    }

tmp-codegen-diff/aws-sdk/sdk/ec2/src/operation/restore_address_to_classic.rs

@@ -1,1 +40,45 @@
    1      1   
// Code generated by software.amazon.smithy.rust.codegen.smithy-rs. DO NOT EDIT.
    2      2   
/// Orchestration and serialization glue logic for `RestoreAddressToClassic`.
    3      3   
#[derive(::std::clone::Clone, ::std::default::Default, ::std::fmt::Debug)]
    4      4   
#[non_exhaustive]
    5      5   
pub struct RestoreAddressToClassic;
    6      6   
impl RestoreAddressToClassic {
    7      7   
    /// Creates a new `RestoreAddressToClassic`
    8      8   
    pub fn new() -> Self {
    9      9   
        Self
   10     10   
    }
          11  +
    /// The schema for this operation's input shape.
          12  +
    pub const INPUT_SCHEMA: &'static ::aws_smithy_schema::Schema = crate::operation::restore_address_to_classic::RestoreAddressToClassicInput::SCHEMA;
          13  +
    /// The schema for this operation's output shape.
          14  +
    pub const OUTPUT_SCHEMA: &'static ::aws_smithy_schema::Schema =
          15  +
        crate::operation::restore_address_to_classic::RestoreAddressToClassicOutput::SCHEMA;
   11     16   
    pub(crate) async fn orchestrate(
   12     17   
        runtime_plugins: &::aws_smithy_runtime_api::client::runtime_plugin::RuntimePlugins,
   13     18   
        input: crate::operation::restore_address_to_classic::RestoreAddressToClassicInput,
   14     19   
    ) -> ::std::result::Result<
   15     20   
        crate::operation::restore_address_to_classic::RestoreAddressToClassicOutput,
   16     21   
        ::aws_smithy_runtime_api::client::result::SdkError<
   17     22   
            crate::operation::restore_address_to_classic::RestoreAddressToClassicError,
   18     23   
            ::aws_smithy_runtime_api::client::orchestrator::HttpResponse,
   19     24   
        >,
   20     25   
    > {
@@ -118,123 +180,186 @@
  138    143   
                crate::operation::restore_address_to_classic::RestoreAddressToClassicError,
  139    144   
            >::new());
  140    145   
  141    146   
        ::std::borrow::Cow::Owned(rcb)
  142    147   
    }
  143    148   
}
  144    149   
  145    150   
#[derive(Debug)]
  146    151   
struct RestoreAddressToClassicResponseDeserializer;
  147    152   
impl ::aws_smithy_runtime_api::client::ser_de::DeserializeResponse for RestoreAddressToClassicResponseDeserializer {
  148         -
    fn deserialize_nonstreaming(
         153  +
    fn deserialize_nonstreaming_with_config(
  149    154   
        &self,
  150    155   
        response: &::aws_smithy_runtime_api::client::orchestrator::HttpResponse,
         156  +
        _cfg: &::aws_smithy_types::config_bag::ConfigBag,
  151    157   
    ) -> ::aws_smithy_runtime_api::client::interceptors::context::OutputOrError {
  152    158   
        let (success, status) = (response.status().is_success(), response.status().as_u16());
  153    159   
        let headers = response.headers();
  154    160   
        let body = response.body().bytes().expect("body loaded");
  155    161   
        #[allow(unused_mut)]
  156    162   
        let mut force_error = false;
  157    163   
        ::tracing::debug!(request_id = ?::aws_types::request_id::RequestId::request_id(response));
  158    164   
        let parse_result = if !success && status != 200 || force_error {
  159    165   
            crate::protocol_serde::shape_restore_address_to_classic::de_restore_address_to_classic_http_error(status, headers, body)
  160    166   
        } else {

tmp-codegen-diff/aws-sdk/sdk/ec2/src/operation/restore_address_to_classic/_restore_address_to_classic_input.rs

@@ -3,3 +135,147 @@
   23     23   
    "com.amazonaws.ec2.synthetic",
   24     24   
    "RestoreAddressToClassicInput",
   25     25   
);
   26     26   
static RESTOREADDRESSTOCLASSICINPUT_MEMBER_DRY_RUN: ::aws_smithy_schema::Schema = ::aws_smithy_schema::Schema::new_member(
   27     27   
    ::aws_smithy_schema::ShapeId::from_static(
   28     28   
        "com.amazonaws.ec2.synthetic#RestoreAddressToClassicInput$DryRun",
   29     29   
        "com.amazonaws.ec2.synthetic",
   30     30   
        "RestoreAddressToClassicInput",
   31     31   
    ),
   32     32   
    ::aws_smithy_schema::ShapeType::Boolean,
   33         -
    "dry_run",
          33  +
    "DryRun",
   34     34   
    0,
   35     35   
)
   36     36   
.with_xml_name("dryRun");
   37     37   
static RESTOREADDRESSTOCLASSICINPUT_MEMBER_PUBLIC_IP: ::aws_smithy_schema::Schema = ::aws_smithy_schema::Schema::new_member(
   38     38   
    ::aws_smithy_schema::ShapeId::from_static(
   39     39   
        "com.amazonaws.ec2.synthetic#RestoreAddressToClassicInput$PublicIp",
   40     40   
        "com.amazonaws.ec2.synthetic",
   41     41   
        "RestoreAddressToClassicInput",
   42     42   
    ),
   43     43   
    ::aws_smithy_schema::ShapeType::String,
   44         -
    "public_ip",
          44  +
    "PublicIp",
   45     45   
    1,
   46     46   
)
   47     47   
.with_xml_name("publicIp");
   48     48   
static RESTOREADDRESSTOCLASSICINPUT_SCHEMA: ::aws_smithy_schema::Schema = ::aws_smithy_schema::Schema::new_struct(
   49     49   
    RESTOREADDRESSTOCLASSICINPUT_SCHEMA_ID,
   50     50   
    ::aws_smithy_schema::ShapeType::Structure,
   51     51   
    &[
   52     52   
        &RESTOREADDRESSTOCLASSICINPUT_MEMBER_DRY_RUN,
   53     53   
        &RESTOREADDRESSTOCLASSICINPUT_MEMBER_PUBLIC_IP,
   54     54   
    ],
   55     55   
);
   56     56   
impl RestoreAddressToClassicInput {
   57     57   
    /// The schema for this shape.
   58     58   
    pub const SCHEMA: &'static ::aws_smithy_schema::Schema = &RESTOREADDRESSTOCLASSICINPUT_SCHEMA;
   59     59   
}
   60     60   
impl ::aws_smithy_schema::serde::SerializableStruct for RestoreAddressToClassicInput {
   61     61   
    #[allow(unused_variables, clippy::diverging_sub_expression)]
   62     62   
    fn serialize_members(
   63     63   
        &self,
   64     64   
        ser: &mut dyn ::aws_smithy_schema::serde::ShapeSerializer,
   65     65   
    ) -> ::std::result::Result<(), ::aws_smithy_schema::serde::SerdeError> {
   66     66   
        if let Some(ref val) = self.dry_run {
   67     67   
            ser.write_boolean(&RESTOREADDRESSTOCLASSICINPUT_MEMBER_DRY_RUN, *val)?;
   68     68   
        }
   69     69   
        if let Some(ref val) = self.public_ip {
   70     70   
            ser.write_string(&RESTOREADDRESSTOCLASSICINPUT_MEMBER_PUBLIC_IP, val)?;
   71     71   
        }
   72     72   
        Ok(())
   73     73   
    }
   74     74   
}
   75     75   
impl RestoreAddressToClassicInput {
   76     76   
    /// Deserializes this structure from a [`ShapeDeserializer`].
   77         -
    pub fn deserialize<D: ::aws_smithy_schema::serde::ShapeDeserializer>(
   78         -
        deserializer: &mut D,
          77  +
    pub fn deserialize(
          78  +
        deserializer: &mut dyn ::aws_smithy_schema::serde::ShapeDeserializer,
   79     79   
    ) -> ::std::result::Result<Self, ::aws_smithy_schema::serde::SerdeError> {
   80     80   
        #[allow(unused_variables, unused_mut)]
   81     81   
        let mut builder = Self::builder();
   82     82   
        #[allow(
   83     83   
            unused_variables,
   84     84   
            unreachable_code,
   85     85   
            clippy::single_match,
   86     86   
            clippy::match_single_binding,
   87     87   
            clippy::diverging_sub_expression
   88     88   
        )]
   89         -
        deserializer.read_struct(&RESTOREADDRESSTOCLASSICINPUT_SCHEMA, (), |_, member, deser| {
          89  +
        deserializer.read_struct(&RESTOREADDRESSTOCLASSICINPUT_SCHEMA, &mut |member, deser| {
   90     90   
            match member.member_index() {
   91     91   
                Some(0) => {
   92     92   
                    builder.dry_run = Some(deser.read_boolean(member)?);
   93     93   
                }
   94     94   
                Some(1) => {
   95     95   
                    builder.public_ip = Some(deser.read_string(member)?);
   96     96   
                }
   97     97   
                _ => {}
   98     98   
            }
   99     99   
            Ok(())
  100    100   
        })?;
         101  +
        builder.public_ip = builder.public_ip.or(Some(String::new()));
  101    102   
        builder
  102    103   
            .build()
  103    104   
            .map_err(|e| aws_smithy_schema::serde::SerdeError::Custom { message: e.to_string() })
  104    105   
    }
  105    106   
}
         107  +
impl RestoreAddressToClassicInput {
         108  +
    /// Deserializes this structure from a body deserializer and HTTP response.
         109  +
    pub fn deserialize_with_response(
         110  +
        deserializer: &mut dyn ::aws_smithy_schema::serde::ShapeDeserializer,
         111  +
        _headers: &::aws_smithy_runtime_api::http::Headers,
         112  +
        _status: u16,
         113  +
        _body: &[u8],
         114  +
    ) -> ::std::result::Result<Self, ::aws_smithy_schema::serde::SerdeError> {
         115  +
        Self::deserialize(deserializer)
         116  +
    }
         117  +
}
  106    118   
impl RestoreAddressToClassicInput {
  107    119   
    /// Creates a new builder-style object to manufacture [`RestoreAddressToClassicInput`](crate::operation::restore_address_to_classic::RestoreAddressToClassicInput).
  108    120   
    pub fn builder() -> crate::operation::restore_address_to_classic::builders::RestoreAddressToClassicInputBuilder {
  109    121   
        crate::operation::restore_address_to_classic::builders::RestoreAddressToClassicInputBuilder::default()
  110    122   
    }
  111    123   
}
  112    124   
  113    125   
/// A builder for [`RestoreAddressToClassicInput`](crate::operation::restore_address_to_classic::RestoreAddressToClassicInput).
  114    126   
#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::default::Default, ::std::fmt::Debug)]
  115    127   
#[non_exhaustive]

tmp-codegen-diff/aws-sdk/sdk/ec2/src/operation/restore_address_to_classic/_restore_address_to_classic_output.rs

@@ -4,4 +120,168 @@
   24     24   
    "com.amazonaws.ec2.synthetic",
   25     25   
    "RestoreAddressToClassicOutput",
   26     26   
);
   27     27   
static RESTOREADDRESSTOCLASSICOUTPUT_MEMBER_PUBLIC_IP: ::aws_smithy_schema::Schema = ::aws_smithy_schema::Schema::new_member(
   28     28   
    ::aws_smithy_schema::ShapeId::from_static(
   29     29   
        "com.amazonaws.ec2.synthetic#RestoreAddressToClassicOutput$PublicIp",
   30     30   
        "com.amazonaws.ec2.synthetic",
   31     31   
        "RestoreAddressToClassicOutput",
   32     32   
    ),
   33     33   
    ::aws_smithy_schema::ShapeType::String,
   34         -
    "public_ip",
          34  +
    "PublicIp",
   35     35   
    0,
   36     36   
)
   37     37   
.with_xml_name("publicIp");
   38     38   
static RESTOREADDRESSTOCLASSICOUTPUT_MEMBER_STATUS: ::aws_smithy_schema::Schema = ::aws_smithy_schema::Schema::new_member(
   39     39   
    ::aws_smithy_schema::ShapeId::from_static(
   40     40   
        "com.amazonaws.ec2.synthetic#RestoreAddressToClassicOutput$Status",
   41     41   
        "com.amazonaws.ec2.synthetic",
   42     42   
        "RestoreAddressToClassicOutput",
   43     43   
    ),
   44     44   
    ::aws_smithy_schema::ShapeType::String,
   45         -
    "status",
          45  +
    "Status",
   46     46   
    1,
   47     47   
)
   48     48   
.with_xml_name("status");
          49  +
static RESTOREADDRESSTOCLASSICOUTPUT_MEMBER__REQUEST_ID: ::aws_smithy_schema::Schema = ::aws_smithy_schema::Schema::new_member(
          50  +
    ::aws_smithy_schema::ShapeId::from_static("synthetic#request_id", "synthetic", "request_id"),
          51  +
    ::aws_smithy_schema::ShapeType::String,
          52  +
    "request_id",
          53  +
    2,
          54  +
)
          55  +
.with_http_header("x-amzn-requestid");
   49     56   
static RESTOREADDRESSTOCLASSICOUTPUT_SCHEMA: ::aws_smithy_schema::Schema = ::aws_smithy_schema::Schema::new_struct(
   50     57   
    RESTOREADDRESSTOCLASSICOUTPUT_SCHEMA_ID,
   51     58   
    ::aws_smithy_schema::ShapeType::Structure,
   52     59   
    &[
   53     60   
        &RESTOREADDRESSTOCLASSICOUTPUT_MEMBER_PUBLIC_IP,
   54     61   
        &RESTOREADDRESSTOCLASSICOUTPUT_MEMBER_STATUS,
          62  +
        &RESTOREADDRESSTOCLASSICOUTPUT_MEMBER__REQUEST_ID,
   55     63   
    ],
   56     64   
);
   57     65   
impl RestoreAddressToClassicOutput {
   58     66   
    /// The schema for this shape.
   59     67   
    pub const SCHEMA: &'static ::aws_smithy_schema::Schema = &RESTOREADDRESSTOCLASSICOUTPUT_SCHEMA;
   60     68   
}
   61     69   
impl ::aws_smithy_schema::serde::SerializableStruct for RestoreAddressToClassicOutput {
   62     70   
    #[allow(unused_variables, clippy::diverging_sub_expression)]
   63     71   
    fn serialize_members(
   64     72   
        &self,
   65     73   
        ser: &mut dyn ::aws_smithy_schema::serde::ShapeSerializer,
   66     74   
    ) -> ::std::result::Result<(), ::aws_smithy_schema::serde::SerdeError> {
   67     75   
        if let Some(ref val) = self.public_ip {
   68     76   
            ser.write_string(&RESTOREADDRESSTOCLASSICOUTPUT_MEMBER_PUBLIC_IP, val)?;
   69     77   
        }
   70     78   
        if let Some(ref val) = self.status {
   71     79   
            ser.write_string(&RESTOREADDRESSTOCLASSICOUTPUT_MEMBER_STATUS, val.as_str())?;
   72     80   
        }
   73     81   
        Ok(())
   74     82   
    }
   75     83   
}
   76     84   
impl RestoreAddressToClassicOutput {
   77     85   
    /// Deserializes this structure from a [`ShapeDeserializer`].
   78         -
    pub fn deserialize<D: ::aws_smithy_schema::serde::ShapeDeserializer>(
   79         -
        deserializer: &mut D,
          86  +
    pub fn deserialize(
          87  +
        deserializer: &mut dyn ::aws_smithy_schema::serde::ShapeDeserializer,
   80     88   
    ) -> ::std::result::Result<Self, ::aws_smithy_schema::serde::SerdeError> {
   81     89   
        #[allow(unused_variables, unused_mut)]
   82     90   
        let mut builder = Self::builder();
   83     91   
        #[allow(
   84     92   
            unused_variables,
   85     93   
            unreachable_code,
   86     94   
            clippy::single_match,
   87     95   
            clippy::match_single_binding,
   88     96   
            clippy::diverging_sub_expression
   89     97   
        )]
   90         -
        deserializer.read_struct(&RESTOREADDRESSTOCLASSICOUTPUT_SCHEMA, (), |_, member, deser| {
          98  +
        deserializer.read_struct(&RESTOREADDRESSTOCLASSICOUTPUT_SCHEMA, &mut |member, deser| {
          99  +
            match member.member_index() {
         100  +
                Some(0) => {
         101  +
                    builder.public_ip = Some(deser.read_string(member)?);
         102  +
                }
         103  +
                Some(1) => {
         104  +
                    builder.status = Some(crate::types::Status::from(deser.read_string(member)?.as_str()));
         105  +
                }
         106  +
                Some(2) => {
         107  +
                    builder._request_id = Some(deser.read_string(member)?);
         108  +
                }
         109  +
                _ => {}
         110  +
            }
         111  +
            Ok(())
         112  +
        })?;
         113  +
        Ok(builder.build())
         114  +
    }
         115  +
}
         116  +
impl RestoreAddressToClassicOutput {
         117  +
    /// Deserializes this structure from a body deserializer and HTTP response headers.
         118  +
    /// Header-bound members are read directly from headers, avoiding runtime
         119  +
    /// member iteration overhead. Body members are read via the deserializer.
         120  +
    pub fn deserialize_with_response(
         121  +
        deserializer: &mut dyn ::aws_smithy_schema::serde::ShapeDeserializer,
         122  +
        headers: &::aws_smithy_runtime_api::http::Headers,
         123  +
        _status: u16,
         124  +
        _body: &[u8],
         125  +
    ) -> ::std::result::Result<Self, ::aws_smithy_schema::serde::SerdeError> {
         126  +
        #[allow(unused_variables, unused_mut)]
         127  +
        let mut builder = Self::builder();
         128  +
        if let Some(val) = headers.get("x-amzn-requestid") {
         129  +
            builder._request_id = Some(val.to_string());
         130  +
        }
         131  +
        #[allow(
         132  +
            unused_variables,
         133  +
            unreachable_code,
         134  +
            clippy::single_match,
         135  +
            clippy::match_single_binding,
         136  +
            clippy::diverging_sub_expression
         137  +
        )]
         138  +
        deserializer.read_struct(&RESTOREADDRESSTOCLASSICOUTPUT_SCHEMA, &mut |member, deser| {
   91    139   
            match member.member_index() {
   92    140   
                Some(0) => {
   93    141   
                    builder.public_ip = Some(deser.read_string(member)?);
   94    142   
                }
   95    143   
                Some(1) => {
   96    144   
                    builder.status = Some(crate::types::Status::from(deser.read_string(member)?.as_str()));
   97    145   
                }
   98    146   
                _ => {}
   99    147   
            }
  100    148   
            Ok(())

tmp-codegen-diff/aws-sdk/sdk/ec2/src/operation/restore_image_from_recycle_bin.rs

@@ -1,1 +40,46 @@
    1      1   
// Code generated by software.amazon.smithy.rust.codegen.smithy-rs. DO NOT EDIT.
    2      2   
/// Orchestration and serialization glue logic for `RestoreImageFromRecycleBin`.
    3      3   
#[derive(::std::clone::Clone, ::std::default::Default, ::std::fmt::Debug)]
    4      4   
#[non_exhaustive]
    5      5   
pub struct RestoreImageFromRecycleBin;
    6      6   
impl RestoreImageFromRecycleBin {
    7      7   
    /// Creates a new `RestoreImageFromRecycleBin`
    8      8   
    pub fn new() -> Self {
    9      9   
        Self
   10     10   
    }
          11  +
    /// The schema for this operation's input shape.
          12  +
    pub const INPUT_SCHEMA: &'static ::aws_smithy_schema::Schema =
          13  +
        crate::operation::restore_image_from_recycle_bin::RestoreImageFromRecycleBinInput::SCHEMA;
          14  +
    /// The schema for this operation's output shape.
          15  +
    pub const OUTPUT_SCHEMA: &'static ::aws_smithy_schema::Schema =
          16  +
        crate::operation::restore_image_from_recycle_bin::RestoreImageFromRecycleBinOutput::SCHEMA;
   11     17   
    pub(crate) async fn orchestrate(
   12     18   
        runtime_plugins: &::aws_smithy_runtime_api::client::runtime_plugin::RuntimePlugins,
   13     19   
        input: crate::operation::restore_image_from_recycle_bin::RestoreImageFromRecycleBinInput,
   14     20   
    ) -> ::std::result::Result<
   15     21   
        crate::operation::restore_image_from_recycle_bin::RestoreImageFromRecycleBinOutput,
   16     22   
        ::aws_smithy_runtime_api::client::result::SdkError<
   17     23   
            crate::operation::restore_image_from_recycle_bin::RestoreImageFromRecycleBinError,
   18     24   
            ::aws_smithy_runtime_api::client::orchestrator::HttpResponse,
   19     25   
        >,
   20     26   
    > {
@@ -118,124 +180,187 @@
  138    144   
                crate::operation::restore_image_from_recycle_bin::RestoreImageFromRecycleBinError,
  139    145   
            >::new());
  140    146   
  141    147   
        ::std::borrow::Cow::Owned(rcb)
  142    148   
    }
  143    149   
}
  144    150   
  145    151   
#[derive(Debug)]
  146    152   
struct RestoreImageFromRecycleBinResponseDeserializer;
  147    153   
impl ::aws_smithy_runtime_api::client::ser_de::DeserializeResponse for RestoreImageFromRecycleBinResponseDeserializer {
  148         -
    fn deserialize_nonstreaming(
         154  +
    fn deserialize_nonstreaming_with_config(
  149    155   
        &self,
  150    156   
        response: &::aws_smithy_runtime_api::client::orchestrator::HttpResponse,
         157  +
        _cfg: &::aws_smithy_types::config_bag::ConfigBag,
  151    158   
    ) -> ::aws_smithy_runtime_api::client::interceptors::context::OutputOrError {
  152    159   
        let (success, status) = (response.status().is_success(), response.status().as_u16());
  153    160   
        let headers = response.headers();
  154    161   
        let body = response.body().bytes().expect("body loaded");
  155    162   
        #[allow(unused_mut)]
  156    163   
        let mut force_error = false;
  157    164   
        ::tracing::debug!(request_id = ?::aws_types::request_id::RequestId::request_id(response));
  158    165   
        let parse_result = if !success && status != 200 || force_error {
  159    166   
            crate::protocol_serde::shape_restore_image_from_recycle_bin::de_restore_image_from_recycle_bin_http_error(status, headers, body)
  160    167   
        } else {

tmp-codegen-diff/aws-sdk/sdk/ec2/src/operation/restore_image_from_recycle_bin/_restore_image_from_recycle_bin_input.rs

@@ -3,3 +133,145 @@
   23     23   
    "com.amazonaws.ec2.synthetic",
   24     24   
    "RestoreImageFromRecycleBinInput",
   25     25   
);
   26     26   
static RESTOREIMAGEFROMRECYCLEBININPUT_MEMBER_IMAGE_ID: ::aws_smithy_schema::Schema = ::aws_smithy_schema::Schema::new_member(
   27     27   
    ::aws_smithy_schema::ShapeId::from_static(
   28     28   
        "com.amazonaws.ec2.synthetic#RestoreImageFromRecycleBinInput$ImageId",
   29     29   
        "com.amazonaws.ec2.synthetic",
   30     30   
        "RestoreImageFromRecycleBinInput",
   31     31   
    ),
   32     32   
    ::aws_smithy_schema::ShapeType::String,
   33         -
    "image_id",
          33  +
    "ImageId",
   34     34   
    0,
   35     35   
);
   36     36   
static RESTOREIMAGEFROMRECYCLEBININPUT_MEMBER_DRY_RUN: ::aws_smithy_schema::Schema = ::aws_smithy_schema::Schema::new_member(
   37     37   
    ::aws_smithy_schema::ShapeId::from_static(
   38     38   
        "com.amazonaws.ec2.synthetic#RestoreImageFromRecycleBinInput$DryRun",
   39     39   
        "com.amazonaws.ec2.synthetic",
   40     40   
        "RestoreImageFromRecycleBinInput",
   41     41   
    ),
   42     42   
    ::aws_smithy_schema::ShapeType::Boolean,
   43         -
    "dry_run",
          43  +
    "DryRun",
   44     44   
    1,
   45     45   
);
   46     46   
static RESTOREIMAGEFROMRECYCLEBININPUT_SCHEMA: ::aws_smithy_schema::Schema = ::aws_smithy_schema::Schema::new_struct(
   47     47   
    RESTOREIMAGEFROMRECYCLEBININPUT_SCHEMA_ID,
   48     48   
    ::aws_smithy_schema::ShapeType::Structure,
   49     49   
    &[
   50     50   
        &RESTOREIMAGEFROMRECYCLEBININPUT_MEMBER_IMAGE_ID,
   51     51   
        &RESTOREIMAGEFROMRECYCLEBININPUT_MEMBER_DRY_RUN,
   52     52   
    ],
   53     53   
);
   54     54   
impl RestoreImageFromRecycleBinInput {
   55     55   
    /// The schema for this shape.
   56     56   
    pub const SCHEMA: &'static ::aws_smithy_schema::Schema = &RESTOREIMAGEFROMRECYCLEBININPUT_SCHEMA;
   57     57   
}
   58     58   
impl ::aws_smithy_schema::serde::SerializableStruct for RestoreImageFromRecycleBinInput {
   59     59   
    #[allow(unused_variables, clippy::diverging_sub_expression)]
   60     60   
    fn serialize_members(
   61     61   
        &self,
   62     62   
        ser: &mut dyn ::aws_smithy_schema::serde::ShapeSerializer,
   63     63   
    ) -> ::std::result::Result<(), ::aws_smithy_schema::serde::SerdeError> {
   64     64   
        if let Some(ref val) = self.image_id {
   65     65   
            ser.write_string(&RESTOREIMAGEFROMRECYCLEBININPUT_MEMBER_IMAGE_ID, val)?;
   66     66   
        }
   67     67   
        if let Some(ref val) = self.dry_run {
   68     68   
            ser.write_boolean(&RESTOREIMAGEFROMRECYCLEBININPUT_MEMBER_DRY_RUN, *val)?;
   69     69   
        }
   70     70   
        Ok(())
   71     71   
    }
   72     72   
}
   73     73   
impl RestoreImageFromRecycleBinInput {
   74     74   
    /// Deserializes this structure from a [`ShapeDeserializer`].
   75         -
    pub fn deserialize<D: ::aws_smithy_schema::serde::ShapeDeserializer>(
   76         -
        deserializer: &mut D,
          75  +
    pub fn deserialize(
          76  +
        deserializer: &mut dyn ::aws_smithy_schema::serde::ShapeDeserializer,
   77     77   
    ) -> ::std::result::Result<Self, ::aws_smithy_schema::serde::SerdeError> {
   78     78   
        #[allow(unused_variables, unused_mut)]
   79     79   
        let mut builder = Self::builder();
   80     80   
        #[allow(
   81     81   
            unused_variables,
   82     82   
            unreachable_code,
   83     83   
            clippy::single_match,
   84     84   
            clippy::match_single_binding,
   85     85   
            clippy::diverging_sub_expression
   86     86   
        )]
   87         -
        deserializer.read_struct(&RESTOREIMAGEFROMRECYCLEBININPUT_SCHEMA, (), |_, member, deser| {
          87  +
        deserializer.read_struct(&RESTOREIMAGEFROMRECYCLEBININPUT_SCHEMA, &mut |member, deser| {
   88     88   
            match member.member_index() {
   89     89   
                Some(0) => {
   90     90   
                    builder.image_id = Some(deser.read_string(member)?);
   91     91   
                }
   92     92   
                Some(1) => {
   93     93   
                    builder.dry_run = Some(deser.read_boolean(member)?);
   94     94   
                }
   95     95   
                _ => {}
   96     96   
            }
   97     97   
            Ok(())
   98     98   
        })?;
          99  +
        builder.image_id = builder.image_id.or(Some(String::new()));
   99    100   
        builder
  100    101   
            .build()
  101    102   
            .map_err(|e| aws_smithy_schema::serde::SerdeError::Custom { message: e.to_string() })
  102    103   
    }
  103    104   
}
         105  +
impl RestoreImageFromRecycleBinInput {
         106  +
    /// Deserializes this structure from a body deserializer and HTTP response.
         107  +
    pub fn deserialize_with_response(
         108  +
        deserializer: &mut dyn ::aws_smithy_schema::serde::ShapeDeserializer,
         109  +
        _headers: &::aws_smithy_runtime_api::http::Headers,
         110  +
        _status: u16,
         111  +
        _body: &[u8],
         112  +
    ) -> ::std::result::Result<Self, ::aws_smithy_schema::serde::SerdeError> {
         113  +
        Self::deserialize(deserializer)
         114  +
    }
         115  +
}
  104    116   
impl RestoreImageFromRecycleBinInput {
  105    117   
    /// Creates a new builder-style object to manufacture [`RestoreImageFromRecycleBinInput`](crate::operation::restore_image_from_recycle_bin::RestoreImageFromRecycleBinInput).
  106    118   
    pub fn builder() -> crate::operation::restore_image_from_recycle_bin::builders::RestoreImageFromRecycleBinInputBuilder {
  107    119   
        crate::operation::restore_image_from_recycle_bin::builders::RestoreImageFromRecycleBinInputBuilder::default()
  108    120   
    }
  109    121   
}
  110    122   
  111    123   
/// A builder for [`RestoreImageFromRecycleBinInput`](crate::operation::restore_image_from_recycle_bin::RestoreImageFromRecycleBinInput).
  112    124   
#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::default::Default, ::std::fmt::Debug)]
  113    125   
#[non_exhaustive]

tmp-codegen-diff/aws-sdk/sdk/ec2/src/operation/restore_image_from_recycle_bin/_restore_image_from_recycle_bin_output.rs

@@ -1,1 +97,144 @@
   18     18   
    "com.amazonaws.ec2.synthetic",
   19     19   
    "RestoreImageFromRecycleBinOutput",
   20     20   
);
   21     21   
static RESTOREIMAGEFROMRECYCLEBINOUTPUT_MEMBER_RETURN: ::aws_smithy_schema::Schema = ::aws_smithy_schema::Schema::new_member(
   22     22   
    ::aws_smithy_schema::ShapeId::from_static(
   23     23   
        "com.amazonaws.ec2.synthetic#RestoreImageFromRecycleBinOutput$Return",
   24     24   
        "com.amazonaws.ec2.synthetic",
   25     25   
        "RestoreImageFromRecycleBinOutput",
   26     26   
    ),
   27     27   
    ::aws_smithy_schema::ShapeType::Boolean,
   28         -
    "r##return",
          28  +
    "Return",
   29     29   
    0,
   30     30   
)
   31     31   
.with_xml_name("return");
          32  +
static RESTOREIMAGEFROMRECYCLEBINOUTPUT_MEMBER__REQUEST_ID: ::aws_smithy_schema::Schema = ::aws_smithy_schema::Schema::new_member(
          33  +
    ::aws_smithy_schema::ShapeId::from_static("synthetic#request_id", "synthetic", "request_id"),
          34  +
    ::aws_smithy_schema::ShapeType::String,
          35  +
    "request_id",
          36  +
    1,
          37  +
)
          38  +
.with_http_header("x-amzn-requestid");
   32     39   
static RESTOREIMAGEFROMRECYCLEBINOUTPUT_SCHEMA: ::aws_smithy_schema::Schema = ::aws_smithy_schema::Schema::new_struct(
   33     40   
    RESTOREIMAGEFROMRECYCLEBINOUTPUT_SCHEMA_ID,
   34     41   
    ::aws_smithy_schema::ShapeType::Structure,
   35         -
    &[&RESTOREIMAGEFROMRECYCLEBINOUTPUT_MEMBER_RETURN],
          42  +
    &[
          43  +
        &RESTOREIMAGEFROMRECYCLEBINOUTPUT_MEMBER_RETURN,
          44  +
        &RESTOREIMAGEFROMRECYCLEBINOUTPUT_MEMBER__REQUEST_ID,
          45  +
    ],
   36     46   
);
   37     47   
impl RestoreImageFromRecycleBinOutput {
   38     48   
    /// The schema for this shape.
   39     49   
    pub const SCHEMA: &'static ::aws_smithy_schema::Schema = &RESTOREIMAGEFROMRECYCLEBINOUTPUT_SCHEMA;
   40     50   
}
   41     51   
impl ::aws_smithy_schema::serde::SerializableStruct for RestoreImageFromRecycleBinOutput {
   42     52   
    #[allow(unused_variables, clippy::diverging_sub_expression)]
   43     53   
    fn serialize_members(
   44     54   
        &self,
   45     55   
        ser: &mut dyn ::aws_smithy_schema::serde::ShapeSerializer,
   46     56   
    ) -> ::std::result::Result<(), ::aws_smithy_schema::serde::SerdeError> {
   47     57   
        if let Some(ref val) = self.r#return {
   48     58   
            ser.write_boolean(&RESTOREIMAGEFROMRECYCLEBINOUTPUT_MEMBER_RETURN, *val)?;
   49     59   
        }
   50     60   
        Ok(())
   51     61   
    }
   52     62   
}
   53     63   
impl RestoreImageFromRecycleBinOutput {
   54     64   
    /// Deserializes this structure from a [`ShapeDeserializer`].
   55         -
    pub fn deserialize<D: ::aws_smithy_schema::serde::ShapeDeserializer>(
   56         -
        deserializer: &mut D,
          65  +
    pub fn deserialize(
          66  +
        deserializer: &mut dyn ::aws_smithy_schema::serde::ShapeDeserializer,
   57     67   
    ) -> ::std::result::Result<Self, ::aws_smithy_schema::serde::SerdeError> {
   58     68   
        #[allow(unused_variables, unused_mut)]
   59     69   
        let mut builder = Self::builder();
   60     70   
        #[allow(
   61     71   
            unused_variables,
   62     72   
            unreachable_code,
   63     73   
            clippy::single_match,
   64     74   
            clippy::match_single_binding,
   65     75   
            clippy::diverging_sub_expression
   66     76   
        )]
   67         -
        deserializer.read_struct(&RESTOREIMAGEFROMRECYCLEBINOUTPUT_SCHEMA, (), |_, member, deser| {
          77  +
        deserializer.read_struct(&RESTOREIMAGEFROMRECYCLEBINOUTPUT_SCHEMA, &mut |member, deser| {
          78  +
            match member.member_index() {
          79  +
                Some(0) => {
          80  +
                    builder.r#return = Some(deser.read_boolean(member)?);
          81  +
                }
          82  +
                Some(1) => {
          83  +
                    builder._request_id = Some(deser.read_string(member)?);
          84  +
                }
          85  +
                _ => {}
          86  +
            }
          87  +
            Ok(())
          88  +
        })?;
          89  +
        Ok(builder.build())
          90  +
    }
          91  +
}
          92  +
impl RestoreImageFromRecycleBinOutput {
          93  +
    /// Deserializes this structure from a body deserializer and HTTP response headers.
          94  +
    /// Header-bound members are read directly from headers, avoiding runtime
          95  +
    /// member iteration overhead. Body members are read via the deserializer.
          96  +
    pub fn deserialize_with_response(
          97  +
        deserializer: &mut dyn ::aws_smithy_schema::serde::ShapeDeserializer,
          98  +
        headers: &::aws_smithy_runtime_api::http::Headers,
          99  +
        _status: u16,
         100  +
        _body: &[u8],
         101  +
    ) -> ::std::result::Result<Self, ::aws_smithy_schema::serde::SerdeError> {
         102  +
        #[allow(unused_variables, unused_mut)]
         103  +
        let mut builder = Self::builder();
         104  +
        if let Some(val) = headers.get("x-amzn-requestid") {
         105  +
            builder._request_id = Some(val.to_string());
         106  +
        }
         107  +
        #[allow(
         108  +
            unused_variables,
         109  +
            unreachable_code,
         110  +
            clippy::single_match,
         111  +
            clippy::match_single_binding,
         112  +
            clippy::diverging_sub_expression
         113  +
        )]
         114  +
        deserializer.read_struct(&RESTOREIMAGEFROMRECYCLEBINOUTPUT_SCHEMA, &mut |member, deser| {
   68    115   
            match member.member_index() {
   69    116   
                Some(0) => {
   70    117   
                    builder.r#return = Some(deser.read_boolean(member)?);
   71    118   
                }
   72    119   
                _ => {}
   73    120   
            }
   74    121   
            Ok(())
   75    122   
        })?;
   76    123   
        Ok(builder.build())
   77    124   
    }