Struct aws_sdk_wafv2::types::builders::CustomHttpHeaderBuilder
source · #[non_exhaustive]pub struct CustomHttpHeaderBuilder { /* private fields */ }
Expand description
A builder for CustomHttpHeader
.
Implementations§
source§impl CustomHttpHeaderBuilder
impl CustomHttpHeaderBuilder
sourcepub fn name(self, input: impl Into<String>) -> Self
pub fn name(self, input: impl Into<String>) -> Self
The name of the custom header.
For custom request header insertion, when WAF inserts the header into the request, it prefixes this name x-amzn-waf-
, to avoid confusion with the headers that are already in the request. For example, for the header name sample
, WAF inserts the header x-amzn-waf-sample
.
sourcepub fn set_name(self, input: Option<String>) -> Self
pub fn set_name(self, input: Option<String>) -> Self
The name of the custom header.
For custom request header insertion, when WAF inserts the header into the request, it prefixes this name x-amzn-waf-
, to avoid confusion with the headers that are already in the request. For example, for the header name sample
, WAF inserts the header x-amzn-waf-sample
.
sourcepub fn get_name(&self) -> &Option<String>
pub fn get_name(&self) -> &Option<String>
The name of the custom header.
For custom request header insertion, when WAF inserts the header into the request, it prefixes this name x-amzn-waf-
, to avoid confusion with the headers that are already in the request. For example, for the header name sample
, WAF inserts the header x-amzn-waf-sample
.
sourcepub fn value(self, input: impl Into<String>) -> Self
pub fn value(self, input: impl Into<String>) -> Self
The value of the custom header.
This field is required.sourcepub fn build(self) -> Result<CustomHttpHeader, BuildError>
pub fn build(self) -> Result<CustomHttpHeader, BuildError>
Consumes the builder and constructs a CustomHttpHeader
.
This method will fail if any of the following fields are not set:
Trait Implementations§
source§impl Clone for CustomHttpHeaderBuilder
impl Clone for CustomHttpHeaderBuilder
source§fn clone(&self) -> CustomHttpHeaderBuilder
fn clone(&self) -> CustomHttpHeaderBuilder
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source
. Read moresource§impl Debug for CustomHttpHeaderBuilder
impl Debug for CustomHttpHeaderBuilder
source§impl Default for CustomHttpHeaderBuilder
impl Default for CustomHttpHeaderBuilder
source§fn default() -> CustomHttpHeaderBuilder
fn default() -> CustomHttpHeaderBuilder
source§impl PartialEq for CustomHttpHeaderBuilder
impl PartialEq for CustomHttpHeaderBuilder
source§fn eq(&self, other: &CustomHttpHeaderBuilder) -> bool
fn eq(&self, other: &CustomHttpHeaderBuilder) -> bool
self
and other
values to be equal, and is used
by ==
.