Trait ControlChannelClient
pub trait ControlChannelClient: Send {
type Error: Error + Send + Sync + 'static;
// Required methods
fn connect(
&mut self,
endpoint: &OsStr,
) -> impl Future<Output = Result<(), Self::Error>> + Send;
fn send(
&mut self,
bytes: &[u8],
) -> impl Future<Output = Result<(), Self::Error>> + Send;
fn recv(
&mut self,
buf: &mut [u8],
) -> impl Future<Output = Result<usize, Self::Error>> + Send;
}Expand description
Client endpoint of the daemon-to-client control channel.
Each client process owns one ControlChannelClient connected to the
daemon-side ControlChannelServer.
Required Associated Types§
Required Methods§
fn connect(
&mut self,
endpoint: &OsStr,
) -> impl Future<Output = Result<(), Self::Error>> + Send
fn connect( &mut self, endpoint: &OsStr, ) -> impl Future<Output = Result<(), Self::Error>> + Send
Connect to the daemon’s control-channel endpoint identified by
endpoint.
§Arguments
endpoint- Platform-specific endpoint identifier (named pipe name on Windows, UNIX socket path on Linux/macOS).
Dyn Compatibility§
This trait is not dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.