pub trait HostedClose: Send + Sync {
// Required method
fn close<'life0, 'async_trait>(
&'life0 self,
) -> Pin<Box<dyn Future<Output = ()> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait;
}Expand description
What a hosted agent holds beyond its runner, closed once the kernel stops serving that build of the agent: when a change replaced it, the agent was removed, or the kernel stops (spec 3.3 §5.7). A harness closes its toolsets, its container shell’s sessions and distils its sessions’ turns into long-term memory.
§Example
use adk_kernel::agents::HostedClose;
struct Quiet;
#[async_trait::async_trait]
impl HostedClose for Quiet {
async fn close(&self) {}
}Required Methods§
Dyn Compatibility§
This trait is dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety".