pub struct AcpAgentConfig { /* private fields */ }Expand description
Configuration for launching an ACP agent subprocess.
This is local SDK configuration, not an ACP wire-protocol type. It contains only the values used to launch the child process.
use agent_client_protocol::{AcpAgent, AcpAgentConfig};
let agent = AcpAgent::new(
AcpAgentConfig::new("python")
.arg("agent.py")
.env("RUST_LOG", "debug"),
);Implementations§
Source§impl AcpAgentConfig
impl AcpAgentConfig
Sourcepub fn new(command: impl Into<PathBuf>) -> Self
pub fn new(command: impl Into<PathBuf>) -> Self
Create a configuration for the given executable or command name.
Sourcepub fn env(self, name: impl Into<String>, value: impl Into<String>) -> Self
pub fn env(self, name: impl Into<String>, value: impl Into<String>) -> Self
Set one environment variable for the child process.
Sourcepub fn environment(&self) -> &BTreeMap<String, String>
pub fn environment(&self) -> &BTreeMap<String, String>
Environment variables set for the child process.
Trait Implementations§
Source§impl Clone for AcpAgentConfig
impl Clone for AcpAgentConfig
Source§fn clone(&self) -> AcpAgentConfig
fn clone(&self) -> AcpAgentConfig
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 AcpAgentConfig
impl Debug for AcpAgentConfig
Source§impl<'de> Deserialize<'de> for AcpAgentConfig
impl<'de> Deserialize<'de> for AcpAgentConfig
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
impl Eq for AcpAgentConfig
Source§impl PartialEq for AcpAgentConfig
impl PartialEq for AcpAgentConfig
Source§impl Serialize for AcpAgentConfig
impl Serialize for AcpAgentConfig
impl StructuralPartialEq for AcpAgentConfig
Auto Trait Implementations§
impl Freeze for AcpAgentConfig
impl RefUnwindSafe for AcpAgentConfig
impl Send for AcpAgentConfig
impl Sync for AcpAgentConfig
impl Unpin for AcpAgentConfig
impl UnsafeUnpin for AcpAgentConfig
impl UnwindSafe for AcpAgentConfig
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> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> DeserializeOwned for Twhere
T: for<'de> Deserialize<'de>,
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.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> IntoMaybeUndefined<T> for T
impl<T> IntoMaybeUndefined<T> for T
Source§fn into_maybe_undefined(self) -> MaybeUndefined<T>
fn into_maybe_undefined(self) -> MaybeUndefined<T>
Converts this value into a three-state builder argument.
Source§impl<T> IntoOption<T> for T
impl<T> IntoOption<T> for T
Source§fn into_option(self) -> Option<T>
fn into_option(self) -> Option<T>
Converts this value into an optional builder argument.