Skip to main content

ClientServiceExt

Trait ClientServiceExt 

Source
pub trait ClientServiceExt: Sized + Service<RoleClient> {
    // Provided method
    fn serve_with_lifecycle<T, E, A>(
        self,
        transport: T,
        lifecycle: ClientLifecycleMode,
    ) -> impl Future<Output = Result<RunningService<RoleClient, Self>, ClientInitializeError>> + MaybeSendFuture
       where T: IntoTransport<RoleClient, E, A>,
             E: Error + Send + Sync + 'static { ... }
}
Available on crate features mcp and tools only.
Expand description

Client-specific lifecycle entry points.

Provided Methods§

Source

fn serve_with_lifecycle<T, E, A>( self, transport: T, lifecycle: ClientLifecycleMode, ) -> impl Future<Output = Result<RunningService<RoleClient, Self>, ClientInitializeError>> + MaybeSendFuture
where T: IntoTransport<RoleClient, E, A>, E: Error + Send + Sync + 'static,

Dyn Compatibility§

This trait is not dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety".

Implementors§