pub enum FlowSpecComponent {
Show 13 variants
DestinationPrefix(FlowSpecPrefix),
SourcePrefix(FlowSpecPrefix),
IpProtocol(Vec<NumericMatch>),
Port(Vec<NumericMatch>),
DestinationPort(Vec<NumericMatch>),
SourcePort(Vec<NumericMatch>),
IcmpType(Vec<NumericMatch>),
IcmpCode(Vec<NumericMatch>),
TcpFlags(Vec<BitmaskMatch>),
PacketLength(Vec<NumericMatch>),
Dscp(Vec<NumericMatch>),
Fragment(Vec<BitmaskMatch>),
FlowLabel(Vec<NumericMatch>),
}Expand description
A single FlowSpec match component.
Components are identified by type code (1–13) and must be stored in
ascending type order within a FlowSpecRule.
Variants§
DestinationPrefix(FlowSpecPrefix)
Type 1: Destination IP prefix (IPv4 or IPv6 with offset).
SourcePrefix(FlowSpecPrefix)
Type 2: Source IP prefix (IPv4 or IPv6 with offset).
IpProtocol(Vec<NumericMatch>)
Type 3: IP protocol (e.g., TCP=6, UDP=17).
Port(Vec<NumericMatch>)
Type 4: Port (source or destination).
DestinationPort(Vec<NumericMatch>)
Type 5: Destination port.
SourcePort(Vec<NumericMatch>)
Type 6: Source port.
IcmpType(Vec<NumericMatch>)
Type 7: ICMP type.
IcmpCode(Vec<NumericMatch>)
Type 8: ICMP code.
TcpFlags(Vec<BitmaskMatch>)
Type 9: TCP flags.
PacketLength(Vec<NumericMatch>)
Type 10: Packet length.
Dscp(Vec<NumericMatch>)
Type 11: DSCP value.
Fragment(Vec<BitmaskMatch>)
Type 12: Fragment flags.
FlowLabel(Vec<NumericMatch>)
Type 13: Flow label (IPv6 only, RFC 8956).
Implementations§
Trait Implementations§
Source§impl Clone for FlowSpecComponent
impl Clone for FlowSpecComponent
Source§fn clone(&self) -> FlowSpecComponent
fn clone(&self) -> FlowSpecComponent
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 Debug for FlowSpecComponent
impl Debug for FlowSpecComponent
Source§impl Hash for FlowSpecComponent
impl Hash for FlowSpecComponent
Source§impl Ord for FlowSpecComponent
impl Ord for FlowSpecComponent
Source§fn cmp(&self, other: &FlowSpecComponent) -> Ordering
fn cmp(&self, other: &FlowSpecComponent) -> Ordering
1.21.0 · Source§fn max(self, other: Self) -> Selfwhere
Self: Sized,
fn max(self, other: Self) -> Selfwhere
Self: Sized,
Compares and returns the maximum of two values. Read more
Source§impl PartialEq for FlowSpecComponent
impl PartialEq for FlowSpecComponent
Source§impl PartialOrd for FlowSpecComponent
impl PartialOrd for FlowSpecComponent
impl Eq for FlowSpecComponent
impl StructuralPartialEq for FlowSpecComponent
Auto Trait Implementations§
impl Freeze for FlowSpecComponent
impl RefUnwindSafe for FlowSpecComponent
impl Send for FlowSpecComponent
impl Sync for FlowSpecComponent
impl Unpin for FlowSpecComponent
impl UnsafeUnpin for FlowSpecComponent
impl UnwindSafe for FlowSpecComponent
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