#[non_exhaustive]pub struct SecurityPolicyRuleHttpHeaderActionHttpHeaderOption {
pub header_name: Option<String>,
pub header_value: Option<String>,
/* private fields */
}Available on crate features
organization-security-policies or region-security-policies or security-policies only.Fields (Non-exhaustive)§
This struct is marked as non-exhaustive
Non-exhaustive structs could have additional fields added in future. Therefore, non-exhaustive structs cannot be constructed in external crates using the traditional
Struct { .. } syntax; cannot be matched against without a wildcard ..; and struct update syntax will not work.header_name: Option<String>The name of the header to set.
header_value: Option<String>The value to set the named header to.
Implementations§
Source§impl SecurityPolicyRuleHttpHeaderActionHttpHeaderOption
impl SecurityPolicyRuleHttpHeaderActionHttpHeaderOption
pub fn new() -> Self
Sourcepub fn set_header_name<T>(self, v: T) -> Self
pub fn set_header_name<T>(self, v: T) -> Self
Sets the value of header_name.
§Example
ⓘ
let x = SecurityPolicyRuleHttpHeaderActionHttpHeaderOption::new().set_header_name("example");Sourcepub fn set_or_clear_header_name<T>(self, v: Option<T>) -> Self
pub fn set_or_clear_header_name<T>(self, v: Option<T>) -> Self
Sets or clears the value of header_name.
§Example
ⓘ
let x = SecurityPolicyRuleHttpHeaderActionHttpHeaderOption::new().set_or_clear_header_name(Some("example"));
let x = SecurityPolicyRuleHttpHeaderActionHttpHeaderOption::new().set_or_clear_header_name(None::<String>);Sourcepub fn set_header_value<T>(self, v: T) -> Self
pub fn set_header_value<T>(self, v: T) -> Self
Sets the value of header_value.
§Example
ⓘ
let x = SecurityPolicyRuleHttpHeaderActionHttpHeaderOption::new().set_header_value("example");Sourcepub fn set_or_clear_header_value<T>(self, v: Option<T>) -> Self
pub fn set_or_clear_header_value<T>(self, v: Option<T>) -> Self
Sets or clears the value of header_value.
§Example
ⓘ
let x = SecurityPolicyRuleHttpHeaderActionHttpHeaderOption::new().set_or_clear_header_value(Some("example"));
let x = SecurityPolicyRuleHttpHeaderActionHttpHeaderOption::new().set_or_clear_header_value(None::<String>);Trait Implementations§
Source§impl Clone for SecurityPolicyRuleHttpHeaderActionHttpHeaderOption
impl Clone for SecurityPolicyRuleHttpHeaderActionHttpHeaderOption
Source§fn clone(&self) -> SecurityPolicyRuleHttpHeaderActionHttpHeaderOption
fn clone(&self) -> SecurityPolicyRuleHttpHeaderActionHttpHeaderOption
Returns a duplicate 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 moreSource§impl Default for SecurityPolicyRuleHttpHeaderActionHttpHeaderOption
impl Default for SecurityPolicyRuleHttpHeaderActionHttpHeaderOption
Source§fn default() -> SecurityPolicyRuleHttpHeaderActionHttpHeaderOption
fn default() -> SecurityPolicyRuleHttpHeaderActionHttpHeaderOption
Returns the “default value” for a type. Read more
Source§impl PartialEq for SecurityPolicyRuleHttpHeaderActionHttpHeaderOption
impl PartialEq for SecurityPolicyRuleHttpHeaderActionHttpHeaderOption
Source§fn eq(&self, other: &SecurityPolicyRuleHttpHeaderActionHttpHeaderOption) -> bool
fn eq(&self, other: &SecurityPolicyRuleHttpHeaderActionHttpHeaderOption) -> bool
Tests for
self and other values to be equal, and is used by ==.impl StructuralPartialEq for SecurityPolicyRuleHttpHeaderActionHttpHeaderOption
Auto Trait Implementations§
impl Freeze for SecurityPolicyRuleHttpHeaderActionHttpHeaderOption
impl RefUnwindSafe for SecurityPolicyRuleHttpHeaderActionHttpHeaderOption
impl Send for SecurityPolicyRuleHttpHeaderActionHttpHeaderOption
impl Sync for SecurityPolicyRuleHttpHeaderActionHttpHeaderOption
impl Unpin for SecurityPolicyRuleHttpHeaderActionHttpHeaderOption
impl UnwindSafe for SecurityPolicyRuleHttpHeaderActionHttpHeaderOption
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more