pub struct PushOpNewruleDoRequest<Prev: Rec> { /* private fields */ }Available on crate feature
nftables only.Expand description
Create a new rule.
Implementations§
Source§impl<Prev: Rec> PushOpNewruleDoRequest<Prev>
impl<Prev: Rec> PushOpNewruleDoRequest<Prev>
pub fn new(prev: Prev, header: &PushNfgenmsg) -> Self
pub fn end_nested(self) -> Prev
Sourcepub fn push_table(self, value: &CStr) -> Self
pub fn push_table(self, value: &CStr) -> Self
name of the table containing the rule
Sourcepub fn push_table_bytes(self, value: &[u8]) -> Self
pub fn push_table_bytes(self, value: &[u8]) -> Self
name of the table containing the rule
Sourcepub fn push_chain(self, value: &CStr) -> Self
pub fn push_chain(self, value: &CStr) -> Self
name of the chain containing the rule
Sourcepub fn push_chain_bytes(self, value: &[u8]) -> Self
pub fn push_chain_bytes(self, value: &[u8]) -> Self
name of the chain containing the rule
Sourcepub fn push_handle(self, value: u64) -> Self
pub fn push_handle(self, value: u64) -> Self
numeric handle of the rule
Sourcepub fn nested_expressions(self) -> PushExprListAttrs<Self>
pub fn nested_expressions(self) -> PushExprListAttrs<Self>
list of expressions
Sourcepub fn nested_compat(self) -> PushRuleCompatAttrs<Self>
pub fn nested_compat(self) -> PushRuleCompatAttrs<Self>
compatibility specifications of the rule
Sourcepub fn push_position(self, value: u64) -> Self
pub fn push_position(self, value: u64) -> Self
numeric handle of the previous rule
Sourcepub fn push_userdata(self, value: &[u8]) -> Self
pub fn push_userdata(self, value: &[u8]) -> Self
user data
Sourcepub fn push_position_id(self, value: u32) -> Self
pub fn push_position_id(self, value: u32) -> Self
transaction unique identifier of the previous rule
Sourcepub fn push_chain_id(self, value: u32) -> Self
pub fn push_chain_id(self, value: u32) -> Self
add the rule to chain by ID, alternative to chain name
Trait Implementations§
Source§impl<Prev: Rec> Drop for PushOpNewruleDoRequest<Prev>
impl<Prev: Rec> Drop for PushOpNewruleDoRequest<Prev>
Auto Trait Implementations§
impl<Prev> Freeze for PushOpNewruleDoRequest<Prev>where
Prev: Freeze,
impl<Prev> RefUnwindSafe for PushOpNewruleDoRequest<Prev>where
Prev: RefUnwindSafe,
impl<Prev> Send for PushOpNewruleDoRequest<Prev>where
Prev: Send,
impl<Prev> Sync for PushOpNewruleDoRequest<Prev>where
Prev: Sync,
impl<Prev> Unpin for PushOpNewruleDoRequest<Prev>where
Prev: Unpin,
impl<Prev> UnwindSafe for PushOpNewruleDoRequest<Prev>where
Prev: UnwindSafe,
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