pub struct Rule {
pub id: Option<String>,
pub kind: GroupKind,
pub label: String,
pub matcher: MatchSpec,
pub exclude: Option<MatchSpec>,
pub session_key: Option<String>,
pub priority: i32,
pub protected: bool,
}Expand description
One detection rule (TOML [[group]]).
Fields§
§id: Option<String>Optional stable id (“builtin:claude-code”); defaults to the label slug.
kind: GroupKind§label: String§matcher: MatchSpec§exclude: Option<MatchSpec>§session_key: Option<String>“env:KEY” → one group per distinct (hashed) marker value.
priority: i32§protected: boolMatching processes are protected (never offered for actions).
Implementations§
Trait Implementations§
Source§impl<'de> Deserialize<'de> for Rule
impl<'de> Deserialize<'de> for Rule
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
impl StructuralPartialEq for Rule
Auto Trait Implementations§
impl Forget for Rule
impl Freeze for Rule
impl Move for Rule
impl RefUnwindSafe for Rule
impl Send for Rulewhere
RawVecInner: Send,
impl Sync for Rulewhere
RawVecInner: Sync,
impl Unpin for Rule
impl UnsafeUnpin for Rulewhere
*const u8 is !null: UnsafeUnpin,
PhantomData<u8>: UnsafeUnpin,
PhantomData<String>: UnsafeUnpin,
impl UnwindSafe for Rulewhere
RawVecInner: 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