pub struct DaemonHost { /* private fields */ }Expand description
Server-specific host for the daemon. Owns event channels and session state.
Trait Implementations§
Source§impl Clone for DaemonHost
impl Clone for DaemonHost
Source§fn clone(&self) -> DaemonHost
fn clone(&self) -> DaemonHost
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Host for DaemonHost
impl Host for DaemonHost
Source§async fn dispatch_ask_user(
&self,
args: &str,
conversation_id: Option<u64>,
) -> Result<String, String>
async fn dispatch_ask_user( &self, args: &str, conversation_id: Option<u64>, ) -> Result<String, String>
Handle
ask_user — block until user replies. Read moreSource§async fn dispatch_delegate(
&self,
args: &str,
_agent: &str,
) -> Result<String, String>
async fn dispatch_delegate( &self, args: &str, _agent: &str, ) -> Result<String, String>
Handle
delegate — spawn sub-agent tasks. Read moreSource§fn conversation_cwd(&self, conversation_id: u64) -> Option<PathBuf>
fn conversation_cwd(&self, conversation_id: u64) -> Option<PathBuf>
Resolve the working directory for a conversation.
Returns
None to fall back to the runtime’s base cwd.Source§fn on_agent_event(&self, agent: &str, conversation_id: u64, event: &AgentEvent)
fn on_agent_event(&self, agent: &str, conversation_id: u64, event: &AgentEvent)
Called when an agent event occurs. The daemon uses this to broadcast
protobuf events to console subscribers. Default: no-op.
Source§async fn reply_to_ask(&self, session: u64, content: String) -> Result<bool>
async fn reply_to_ask(&self, session: u64, content: String) -> Result<bool>
Deliver a user reply to a pending
ask_user tool call.
Returns true if a pending ask was found and resolved.Source§async fn set_conversation_cwd(&self, conversation: u64, cwd: PathBuf)
async fn set_conversation_cwd(&self, conversation: u64, cwd: PathBuf)
Set the working directory override for a conversation.
Source§async fn clear_conversation_state(&self, conversation: u64)
async fn clear_conversation_state(&self, conversation: u64)
Clear all per-conversation state (pending asks, CWD overrides).
Source§fn subscribe_events(&self) -> Option<Receiver<AgentEventMsg>>
fn subscribe_events(&self) -> Option<Receiver<AgentEventMsg>>
Subscribe to agent events. Returns
None if event broadcasting
is not supported by this host.Auto Trait Implementations§
impl Freeze for DaemonHost
impl !RefUnwindSafe for DaemonHost
impl Send for DaemonHost
impl Sync for DaemonHost
impl Unpin for DaemonHost
impl UnsafeUnpin for DaemonHost
impl !UnwindSafe for DaemonHost
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