pub struct GuardrailEnforcer;Expand description
@acp:summary “Enforces guardrails on proposed changes”
Implementations§
Source§impl GuardrailEnforcer
impl GuardrailEnforcer
Sourcepub fn can_modify(guardrails: &FileGuardrails) -> GuardrailCheck
pub fn can_modify(guardrails: &FileGuardrails) -> GuardrailCheck
Check if AI should modify this file
Sourcepub fn check_changes(
guardrails: &FileGuardrails,
proposed_content: &str,
) -> GuardrailCheck
pub fn check_changes( guardrails: &FileGuardrails, proposed_content: &str, ) -> GuardrailCheck
Check if proposed changes violate constraints
Auto Trait Implementations§
impl Freeze for GuardrailEnforcer
impl RefUnwindSafe for GuardrailEnforcer
impl Send for GuardrailEnforcer
impl Sync for GuardrailEnforcer
impl Unpin for GuardrailEnforcer
impl UnwindSafe for GuardrailEnforcer
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
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more