#[non_exhaustive]pub struct SecurityPolicyRuleNetworkMatcher {
pub dest_ip_ranges: Vec<String>,
pub dest_ports: Vec<String>,
pub ip_protocols: Vec<String>,
pub src_asns: Vec<u32>,
pub src_ip_ranges: Vec<String>,
pub src_ports: Vec<String>,
pub src_region_codes: Vec<String>,
pub user_defined_fields: Vec<SecurityPolicyRuleNetworkMatcherUserDefinedFieldMatch>,
/* private fields */
}organization-security-policies or region-security-policies or security-policies only.Expand description
Represents a match condition that incoming network traffic is evaluated against.
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.dest_ip_ranges: Vec<String>Destination IPv4/IPv6 addresses or CIDR prefixes, in standard text format.
dest_ports: Vec<String>Destination port numbers for TCP/UDP/SCTP. Each element can be a 16-bit unsigned decimal number (e.g. “80”) or range (e.g. “0-1023”).
ip_protocols: Vec<String>IPv4 protocol / IPv6 next header (after extension headers). Each element can be an 8-bit unsigned decimal number (e.g. “6”), range (e.g. “253-254”), or one of the following protocol names: “tcp”, “udp”, “icmp”, “esp”, “ah”, “ipip”, or “sctp”.
src_asns: Vec<u32>BGP Autonomous System Number associated with the source IP address.
src_ip_ranges: Vec<String>Source IPv4/IPv6 addresses or CIDR prefixes, in standard text format.
src_ports: Vec<String>Source port numbers for TCP/UDP/SCTP. Each element can be a 16-bit unsigned decimal number (e.g. “80”) or range (e.g. “0-1023”).
src_region_codes: Vec<String>Two-letter ISO 3166-1 alpha-2 country code associated with the source IP address.
user_defined_fields: Vec<SecurityPolicyRuleNetworkMatcherUserDefinedFieldMatch>User-defined fields. Each element names a defined field and lists the matching values for that field.
Implementations§
Source§impl SecurityPolicyRuleNetworkMatcher
impl SecurityPolicyRuleNetworkMatcher
Sourcepub fn set_dest_ip_ranges<T, V>(self, v: T) -> Self
pub fn set_dest_ip_ranges<T, V>(self, v: T) -> Self
Sets the value of dest_ip_ranges.
§Example
let x = SecurityPolicyRuleNetworkMatcher::new().set_dest_ip_ranges(["a", "b", "c"]);Sourcepub fn set_dest_ports<T, V>(self, v: T) -> Self
pub fn set_dest_ports<T, V>(self, v: T) -> Self
Sets the value of dest_ports.
§Example
let x = SecurityPolicyRuleNetworkMatcher::new().set_dest_ports(["a", "b", "c"]);Sourcepub fn set_ip_protocols<T, V>(self, v: T) -> Self
pub fn set_ip_protocols<T, V>(self, v: T) -> Self
Sets the value of ip_protocols.
§Example
let x = SecurityPolicyRuleNetworkMatcher::new().set_ip_protocols(["a", "b", "c"]);Sourcepub fn set_src_asns<T, V>(self, v: T) -> Self
pub fn set_src_asns<T, V>(self, v: T) -> Self
Sourcepub fn set_src_ip_ranges<T, V>(self, v: T) -> Self
pub fn set_src_ip_ranges<T, V>(self, v: T) -> Self
Sets the value of src_ip_ranges.
§Example
let x = SecurityPolicyRuleNetworkMatcher::new().set_src_ip_ranges(["a", "b", "c"]);Sourcepub fn set_src_ports<T, V>(self, v: T) -> Self
pub fn set_src_ports<T, V>(self, v: T) -> Self
Sourcepub fn set_src_region_codes<T, V>(self, v: T) -> Self
pub fn set_src_region_codes<T, V>(self, v: T) -> Self
Sets the value of src_region_codes.
§Example
let x = SecurityPolicyRuleNetworkMatcher::new().set_src_region_codes(["a", "b", "c"]);Sourcepub fn set_user_defined_fields<T, V>(self, v: T) -> Self
pub fn set_user_defined_fields<T, V>(self, v: T) -> Self
Sets the value of user_defined_fields.
§Example
use google_cloud_compute_v1::model::SecurityPolicyRuleNetworkMatcherUserDefinedFieldMatch;
let x = SecurityPolicyRuleNetworkMatcher::new()
.set_user_defined_fields([
SecurityPolicyRuleNetworkMatcherUserDefinedFieldMatch::default()/* use setters */,
SecurityPolicyRuleNetworkMatcherUserDefinedFieldMatch::default()/* use (different) setters */,
]);Trait Implementations§
Source§impl Clone for SecurityPolicyRuleNetworkMatcher
impl Clone for SecurityPolicyRuleNetworkMatcher
Source§fn clone(&self) -> SecurityPolicyRuleNetworkMatcher
fn clone(&self) -> SecurityPolicyRuleNetworkMatcher
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreSource§impl Default for SecurityPolicyRuleNetworkMatcher
impl Default for SecurityPolicyRuleNetworkMatcher
Source§fn default() -> SecurityPolicyRuleNetworkMatcher
fn default() -> SecurityPolicyRuleNetworkMatcher
impl StructuralPartialEq for SecurityPolicyRuleNetworkMatcher
Auto Trait Implementations§
impl Freeze for SecurityPolicyRuleNetworkMatcher
impl RefUnwindSafe for SecurityPolicyRuleNetworkMatcher
impl Send for SecurityPolicyRuleNetworkMatcher
impl Sync for SecurityPolicyRuleNetworkMatcher
impl Unpin for SecurityPolicyRuleNetworkMatcher
impl UnsafeUnpin for SecurityPolicyRuleNetworkMatcher
impl UnwindSafe for SecurityPolicyRuleNetworkMatcher
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
impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> DeserializeOwned for Twhere
T: for<'de> Deserialize<'de>,
Source§impl<T> FutureExt for T
impl<T> FutureExt for T
Source§fn with_context(self, otel_cx: Context) -> WithContext<Self>
fn with_context(self, otel_cx: Context) -> WithContext<Self>
Source§fn with_current_context(self) -> WithContext<Self>
fn with_current_context(self) -> WithContext<Self>
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoRequest<T> for T
impl<T> IntoRequest<T> for T
Source§fn into_request(self) -> Request<T>
fn into_request(self) -> Request<T>
T in a tonic::Request