#[non_exhaustive]pub struct ResponseHeadersPolicyContentTypeOptions { /* private fields */ }
Expand description
Determines whether CloudFront includes the X-Content-Type-Options
HTTP response header with its value set to nosniff
.
For more information about the X-Content-Type-Options
HTTP response header, see X-Content-Type-Options in the MDN Web Docs.
Implementations§
source§impl ResponseHeadersPolicyContentTypeOptions
impl ResponseHeadersPolicyContentTypeOptions
sourcepub fn builder() -> Builder
pub fn builder() -> Builder
Creates a new builder-style object to manufacture ResponseHeadersPolicyContentTypeOptions
.
Examples found in repository?
src/xml_deser.rs (line 12514)
12507 12508 12509 12510 12511 12512 12513 12514 12515 12516 12517 12518 12519 12520 12521 12522 12523 12524 12525 12526 12527 12528 12529 12530 12531 12532 12533 12534 12535 12536
pub fn deser_structure_crate_model_response_headers_policy_content_type_options(
decoder: &mut aws_smithy_xml::decode::ScopedDecoder,
) -> Result<
crate::model::ResponseHeadersPolicyContentTypeOptions,
aws_smithy_xml::decode::XmlDecodeError,
> {
#[allow(unused_mut)]
let mut builder = crate::model::ResponseHeadersPolicyContentTypeOptions::builder();
while let Some(mut tag) = decoder.next_tag() {
match tag.start_el() {
s if s.matches("Override") /* Override com.amazonaws.cloudfront#ResponseHeadersPolicyContentTypeOptions$Override */ => {
let var_500 =
Some(
{
<bool as aws_smithy_types::primitive::Parse>::parse_smithy_primitive(
aws_smithy_xml::decode::try_data(&mut tag)?.as_ref()
)
.map_err(|_|aws_smithy_xml::decode::XmlDecodeError::custom("expected (boolean: `com.amazonaws.cloudfront#boolean`)"))
}
?
)
;
builder = builder.set_override(var_500);
}
,
_ => {}
}
}
Ok(builder.build())
}
Trait Implementations§
source§impl Clone for ResponseHeadersPolicyContentTypeOptions
impl Clone for ResponseHeadersPolicyContentTypeOptions
source§fn clone(&self) -> ResponseHeadersPolicyContentTypeOptions
fn clone(&self) -> ResponseHeadersPolicyContentTypeOptions
Returns a copy of the value. Read more
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read more