pub enum RuleTargetKind {
Header,
Body,
}Expand description
What a guardrail rule inspects at the config level.
use praxis_filter::RuleTargetKind;
let target: RuleTargetKind = serde_yaml::from_str("header").unwrap();
assert!(matches!(target, RuleTargetKind::Header));
let target: RuleTargetKind = serde_yaml::from_str("body").unwrap();
assert!(matches!(target, RuleTargetKind::Body));Variants§
Trait Implementations§
Source§impl Debug for RuleTargetKind
impl Debug for RuleTargetKind
Source§impl<'de> Deserialize<'de> for RuleTargetKind
impl<'de> Deserialize<'de> for RuleTargetKind
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
Auto Trait Implementations§
impl Freeze for RuleTargetKind
impl RefUnwindSafe for RuleTargetKind
impl Send for RuleTargetKind
impl Sync for RuleTargetKind
impl Unpin for RuleTargetKind
impl UnsafeUnpin for RuleTargetKind
impl UnwindSafe for RuleTargetKind
Blanket Implementations§
Source§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
Source§impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
T: 'a,
impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
T: 'a,
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