pub enum LifecycleEvent {
PreCompact {
messages: usize,
dropped: usize,
manual: bool,
},
PostCompact {
messages: usize,
dropped: usize,
},
SubagentStart {
task: String,
},
SubagentStop {
task: String,
is_error: bool,
output_len: usize,
},
}Expand description
A loop lifecycle moment an embedder may observe (BP-11, catalog
“Lifecycle hooks, config-registered”): the compaction and subagent
boundaries the CLI’s pre_compact/post_compact/subagent_start/
subagent_stop hook events are fired from. Observational only — a
lifecycle hook can never veto the moment it observes.
Variants§
PreCompact
The live window is about to be compacted: dropped messages in
[first, cut) collapse into one marker; manual is a /compact.
Fields
PostCompact
Compaction finished; the window now holds messages entries.
Fields
SubagentStart
A spawn_subagent call passed validation and is about to run.
SubagentStop
The spawn_subagent call returned (is_error is the tool result’s flag).
Trait Implementations§
Source§impl Clone for LifecycleEvent
impl Clone for LifecycleEvent
Source§fn clone(&self) -> LifecycleEvent
fn clone(&self) -> LifecycleEvent
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 LifecycleEvent
impl Debug for LifecycleEvent
impl Eq for LifecycleEvent
Source§impl PartialEq for LifecycleEvent
impl PartialEq for LifecycleEvent
impl StructuralPartialEq for LifecycleEvent
Auto Trait Implementations§
impl Freeze for LifecycleEvent
impl RefUnwindSafe for LifecycleEvent
impl Send for LifecycleEvent
impl Sync for LifecycleEvent
impl Unpin for LifecycleEvent
impl UnsafeUnpin for LifecycleEvent
impl UnwindSafe for LifecycleEvent
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
impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key and return true if they are equal.