Struct aws_sdk_wafv2::model::LabelMatchStatement
source · [−]#[non_exhaustive]pub struct LabelMatchStatement {
pub scope: Option<LabelMatchScope>,
pub key: Option<String>,
}Expand description
A rule statement that defines a string match search against labels that have been added to the web request by rules that have already run in the web ACL.
The label match statement provides the label or namespace string to search for. The label string can represent a part or all of the fully qualified label name that had been added to the web request. Fully qualified labels have a prefix, optional namespaces, and label name. The prefix identifies the rule group or web ACL context of the rule that added the label. If you do not provide the fully qualified name in your label match string, WAF performs the search for labels that were added in the same context as the label match statement.
Fields (Non-exhaustive)
This struct is marked as non-exhaustive
Struct { .. } syntax; cannot be matched against without a wildcard ..; and struct update syntax will not work.scope: Option<LabelMatchScope>Specify whether you want to match using the label name or just the namespace.
key: Option<String>The string to match against. The setting you provide for this depends on the match statement's Scope setting:
-
If the
ScopeindicatesLABEL, then this specification must include the name and can include any number of preceding namespace specifications and prefix up to providing the fully qualified label name. -
If the
ScopeindicatesNAMESPACE, then this specification can include any number of contiguous namespace strings, and can include the entire label namespace prefix from the rule group or web ACL where the label originates.
Labels are case sensitive and components of a label must be separated by colon, for example NS1:NS2:name.
Implementations
sourceimpl LabelMatchStatement
impl LabelMatchStatement
sourcepub fn scope(&self) -> Option<&LabelMatchScope>
pub fn scope(&self) -> Option<&LabelMatchScope>
Specify whether you want to match using the label name or just the namespace.
sourcepub fn key(&self) -> Option<&str>
pub fn key(&self) -> Option<&str>
The string to match against. The setting you provide for this depends on the match statement's Scope setting:
-
If the
ScopeindicatesLABEL, then this specification must include the name and can include any number of preceding namespace specifications and prefix up to providing the fully qualified label name. -
If the
ScopeindicatesNAMESPACE, then this specification can include any number of contiguous namespace strings, and can include the entire label namespace prefix from the rule group or web ACL where the label originates.
Labels are case sensitive and components of a label must be separated by colon, for example NS1:NS2:name.
sourceimpl LabelMatchStatement
impl LabelMatchStatement
sourcepub fn builder() -> Builder
pub fn builder() -> Builder
Creates a new builder-style object to manufacture LabelMatchStatement
Trait Implementations
sourceimpl Clone for LabelMatchStatement
impl Clone for LabelMatchStatement
sourcefn clone(&self) -> LabelMatchStatement
fn clone(&self) -> LabelMatchStatement
Returns a copy of the value. Read more
1.0.0 · sourcefn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from source. Read more
sourceimpl Debug for LabelMatchStatement
impl Debug for LabelMatchStatement
sourceimpl PartialEq<LabelMatchStatement> for LabelMatchStatement
impl PartialEq<LabelMatchStatement> for LabelMatchStatement
sourcefn eq(&self, other: &LabelMatchStatement) -> bool
fn eq(&self, other: &LabelMatchStatement) -> bool
This method tests for self and other values to be equal, and is used
by ==. Read more
sourcefn ne(&self, other: &LabelMatchStatement) -> bool
fn ne(&self, other: &LabelMatchStatement) -> bool
This method tests for !=.
impl StructuralPartialEq for LabelMatchStatement
Auto Trait Implementations
impl RefUnwindSafe for LabelMatchStatement
impl Send for LabelMatchStatement
impl Sync for LabelMatchStatement
impl Unpin for LabelMatchStatement
impl UnwindSafe for LabelMatchStatement
Blanket Implementations
sourceimpl<T> BorrowMut<T> for T where
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
sourceimpl<T> Instrument for T
impl<T> Instrument for T
sourcefn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
sourcefn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
sourceimpl<T> WithSubscriber for T
impl<T> WithSubscriber for T
sourcefn with_subscriber<S>(self, subscriber: S) -> WithDispatch<Self> where
S: Into<Dispatch>,
fn with_subscriber<S>(self, subscriber: S) -> WithDispatch<Self> where
S: Into<Dispatch>,
Attaches the provided Subscriber to this type, returning a
WithDispatch wrapper. Read more
sourcefn with_current_subscriber(self) -> WithDispatch<Self>
fn with_current_subscriber(self) -> WithDispatch<Self>
Attaches the current default Subscriber to this type, returning a
WithDispatch wrapper. Read more