pub struct IssueLikeHook {
pub kind: &'static str,
}Expand description
KindHook shared by issue and pull_request — both require
properties.number (integer) and properties.project_id (UUID), and,
when present, validate properties.state_reason (governed to a fixed
set for issue per ADR-088 §3; only checked for non-emptiness for
pull_request). See crates/khive-pack-git/docs/api/hooks.md#issuelikehook
for why project_id is required here rather than left to caller
discipline.
Fields§
§kind: &'static strThe note kind this instance validates: "issue" or "pull_request".
Trait Implementations§
Source§impl Debug for IssueLikeHook
impl Debug for IssueLikeHook
Source§impl KindHook for IssueLikeHook
impl KindHook for IssueLikeHook
Source§fn prepare_create<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
_runtime: &'life1 KhiveRuntime,
args: &'life2 mut Value,
) -> Pin<Box<dyn Future<Output = Result<(), RuntimeError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
fn prepare_create<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
_runtime: &'life1 KhiveRuntime,
args: &'life2 mut Value,
) -> Pin<Box<dyn Future<Output = Result<(), RuntimeError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
Mutate args before the storage write. Fill defaults, normalize values,
rearrange user-facing fields into the storage shape expected by the
shared CRUD handler. Read more
Source§fn after_create<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
_runtime: &'life1 KhiveRuntime,
_id: Uuid,
_args: &'life2 Value,
) -> Pin<Box<dyn Future<Output = Result<(), RuntimeError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
fn after_create<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
_runtime: &'life1 KhiveRuntime,
_id: Uuid,
_args: &'life2 Value,
) -> Pin<Box<dyn Future<Output = Result<(), RuntimeError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
Fire side effects after a successful storage write — graph edges,
derived observations, etc. The newly created record’s UUID is passed
so the hook can attach metadata referencing it. Read more
Auto Trait Implementations§
impl Freeze for IssueLikeHook
impl RefUnwindSafe for IssueLikeHook
impl Send for IssueLikeHook
impl Sync for IssueLikeHook
impl Unpin for IssueLikeHook
impl UnsafeUnpin for IssueLikeHook
impl UnwindSafe for IssueLikeHook
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