static GETCONFIGURATIONOUTPUT_MEMBER_CONTENT: ::aws_smithy_schema::Schema<'static> = ::aws_smithy_schema::Schema::new_member(
::aws_smithy_schema::ShapeId::from_parts(
"com.amazonaws.appconfigcloudextension.synthetic#GetConfigurationOutput$content",
"com.amazonaws.appconfigcloudextension.synthetic",
"GetConfigurationOutput",
),
::aws_smithy_schema::ShapeType::Blob,
"content",
0,
);
static GETCONFIGURATIONOUTPUT_MEMBER_CONTENT_TYPE: ::aws_smithy_schema::Schema<'static> = ::aws_smithy_schema::Schema::new_member(
::aws_smithy_schema::ShapeId::from_parts(
"com.amazonaws.appconfigcloudextension.synthetic#GetConfigurationOutput$contentType",
"com.amazonaws.appconfigcloudextension.synthetic",
"GetConfigurationOutput",
),
::aws_smithy_schema::ShapeType::String,
"contentType",
1,
);
static GETCONFIGURATIONOUTPUT_MEMBER_REVISION: ::aws_smithy_schema::Schema<'static> = ::aws_smithy_schema::Schema::new_member(
::aws_smithy_schema::ShapeId::from_parts(
"com.amazonaws.appconfigcloudextension.synthetic#GetConfigurationOutput$revision",
"com.amazonaws.appconfigcloudextension.synthetic",
"GetConfigurationOutput",
),
::aws_smithy_schema::ShapeType::String,
"revision",
2,
);
static GETCONFIGURATIONOUTPUT_MEMBER_VERSION_LABEL: ::aws_smithy_schema::Schema<'static> = ::aws_smithy_schema::Schema::new_member(
::aws_smithy_schema::ShapeId::from_parts(
"com.amazonaws.appconfigcloudextension.synthetic#GetConfigurationOutput$versionLabel",
"com.amazonaws.appconfigcloudextension.synthetic",
"GetConfigurationOutput",
),
::aws_smithy_schema::ShapeType::String,
"versionLabel",
3,
);
static GETCONFIGURATIONOUTPUT_SCHEMA: ::aws_smithy_schema::Schema<'static> = ::aws_smithy_schema::Schema::new_struct(
::aws_smithy_schema::ShapeId::from_parts(
"com.amazonaws.appconfigcloudextension.synthetic#GetConfigurationOutput",
"com.amazonaws.appconfigcloudextension.synthetic",
"GetConfigurationOutput",
),
::aws_smithy_schema::ShapeType::Structure,
&[
&GETCONFIGURATIONOUTPUT_MEMBER_CONTENT,
&GETCONFIGURATIONOUTPUT_MEMBER_CONTENT_TYPE,
&GETCONFIGURATIONOUTPUT_MEMBER_REVISION,
&GETCONFIGURATIONOUTPUT_MEMBER_VERSION_LABEL,
],
)
.with_original_name("GetConfigurationResponse");
impl crate::operation::get_configuration::GetConfigurationOutput {
pub const SCHEMA: &'static ::aws_smithy_schema::Schema<'static> = &GETCONFIGURATIONOUTPUT_SCHEMA;
}
impl ::aws_smithy_schema::serde::SerializableStruct for crate::operation::get_configuration::GetConfigurationOutput {
fn schema(&self) -> &::aws_smithy_schema::Schema<'_> {
Self::SCHEMA
}
#[allow(unused_variables, clippy::diverging_sub_expression)]
fn serialize_members(
&self,
ser: &mut dyn ::aws_smithy_schema::serde::ShapeSerializer,
) -> ::std::result::Result<(), ::aws_smithy_schema::serde::SerdeError> {
{
let val = &self.content;
ser.write_blob(&GETCONFIGURATIONOUTPUT_MEMBER_CONTENT, val.clone())?;
}
{
let val = &self.content_type;
ser.write_string(&GETCONFIGURATIONOUTPUT_MEMBER_CONTENT_TYPE, val)?;
}
{
let val = &self.revision;
ser.write_string(&GETCONFIGURATIONOUTPUT_MEMBER_REVISION, val)?;
}
if let Some(ref val) = self.version_label {
ser.write_string(&GETCONFIGURATIONOUTPUT_MEMBER_VERSION_LABEL, val)?;
}
Ok(())
}
}
impl crate::operation::get_configuration::builders::GetConfigurationOutputBuilder {
#[allow(
unused_variables,
unreachable_code,
clippy::single_match,
clippy::match_single_binding,
clippy::diverging_sub_expression
)]
pub(crate) fn deserialize_members(
&mut self,
deserializer: &mut dyn ::aws_smithy_schema::serde::ShapeDeserializer,
) -> ::std::result::Result<(), ::aws_smithy_schema::serde::SerdeError> {
deserializer.read_struct(&GETCONFIGURATIONOUTPUT_SCHEMA, &mut |member, deser| {
match member.member_index() {
Some(0) => {
self.content = Some(deser.read_blob(member)?);
}
Some(1) => {
self.content_type = Some(deser.read_string(member)?);
}
Some(2) => {
self.revision = Some(deser.read_string(member)?);
}
Some(3) => {
if deser.is_null() {
deser.read_null()?;
} else {
self.version_label = Some(deser.read_string(member)?);
}
}
_ => {}
}
Ok(())
})
}
}
impl crate::operation::get_configuration::GetConfigurationOutput {
pub fn deserialize(
deserializer: &mut dyn ::aws_smithy_schema::serde::ShapeDeserializer,
) -> ::std::result::Result<Self, ::aws_smithy_schema::serde::SerdeError> {
let mut builder = Self::builder();
builder.deserialize_members(deserializer)?;
builder.content = builder.content.or(Some(::aws_smithy_types::Blob::new("")));
builder.content_type = builder.content_type.or(Some(String::new()));
builder.revision = builder.revision.or(Some(String::new()));
builder.build().map_err(|e| aws_smithy_schema::serde::SerdeError::custom(e.to_string()))
}
}