// Code generated by software.amazon.smithy.rust.codegen.smithy-rs. DO NOT EDIT.
pub fn de_body_payload(
    body: &mut ::aws_smithy_types::body::SdkBody,
) -> std::result::Result<
    crate::event_receiver::EventReceiver<crate::types::ResponseStream, crate::types::error::ResponseStreamError>,
    crate::operation::invoke_model_with_response_stream::InvokeModelWithResponseStreamError,
> {
    let unmarshaller = crate::event_stream_serde::ResponseStreamUnmarshaller::new();
    let body = std::mem::replace(body, ::aws_smithy_types::body::SdkBody::taken());
    Ok(crate::event_receiver::EventReceiver::new(::aws_smithy_http::event_stream::Receiver::new(
        unmarshaller,
        body,
    )))
}

pub(crate) fn de_content_type_header(
    header_map: &::aws_smithy_runtime_api::http::Headers,
) -> ::std::result::Result<::std::option::Option<::std::string::String>, ::aws_smithy_http::header::ParseError> {
    let headers = header_map.get_all("X-Amzn-Bedrock-Content-Type");
    ::aws_smithy_http::header::one_or_none(headers)
}

pub(crate) fn de_performance_config_latency_header(
    header_map: &::aws_smithy_runtime_api::http::Headers,
) -> ::std::result::Result<::std::option::Option<crate::types::PerformanceConfigLatency>, ::aws_smithy_http::header::ParseError> {
    let headers = header_map.get_all("X-Amzn-Bedrock-PerformanceConfig-Latency");
    ::aws_smithy_http::header::one_or_none(headers)
}
