pub struct DenyAllFilter {
pub reason: String,
}Expand description
A filter that rejects every call with a fixed reason.
Useful for tests, kill-switch scenarios, and as a baseline for “deny by default” chains. The reason is recorded in the rejected outcome’s output payload.
Fields§
§reason: StringThe fixed reason recorded in every rejected outcome’s output payload.
Implementations§
Trait Implementations§
Source§impl Clone for DenyAllFilter
impl Clone for DenyAllFilter
Source§fn clone(&self) -> DenyAllFilter
fn clone(&self) -> DenyAllFilter
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · 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 DenyAllFilter
impl Debug for DenyAllFilter
Source§impl Default for DenyAllFilter
impl Default for DenyAllFilter
Source§impl ToolUseHook for DenyAllFilter
impl ToolUseHook for DenyAllFilter
Source§fn apply<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
calls: Vec<ToolCallPayload>,
_ctx: &'life1 HookCtx<'life2>,
) -> Pin<Box<dyn Future<Output = HookOutcome> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
fn apply<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
calls: Vec<ToolCallPayload>,
_ctx: &'life1 HookCtx<'life2>,
) -> Pin<Box<dyn Future<Output = HookOutcome> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
Filter the model-emitted batch between receipt and dispatch:
return what to execute and what to reject.
Auto Trait Implementations§
impl Freeze for DenyAllFilter
impl RefUnwindSafe for DenyAllFilter
impl Send for DenyAllFilter
impl Sync for DenyAllFilter
impl Unpin for DenyAllFilter
impl UnsafeUnpin for DenyAllFilter
impl UnwindSafe for DenyAllFilter
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