pub struct RoleClient;Trait Implementations§
Source§impl Clone for RoleClient
impl Clone for RoleClient
Source§fn clone(&self) -> RoleClient
fn clone(&self) -> RoleClient
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 Debug for RoleClient
impl Debug for RoleClient
Source§impl Default for RoleClient
impl Default for RoleClient
Source§fn default() -> RoleClient
fn default() -> RoleClient
Returns the “default value” for a type. Read more
Source§impl PartialEq for RoleClient
impl PartialEq for RoleClient
Source§impl<H> Service<RoleClient> for Hwhere
H: ClientHandler,
impl<H> Service<RoleClient> for Hwhere
H: ClientHandler,
async fn handle_request( &self, request: <RoleClient as ServiceRole>::PeerReq, context: RequestContext<RoleClient>, ) -> Result<<RoleClient as ServiceRole>::Resp, ErrorData>
async fn handle_notification( &self, notification: <RoleClient as ServiceRole>::PeerNot, context: NotificationContext<RoleClient>, ) -> Result<(), ErrorData>
fn get_info(&self) -> <RoleClient as ServiceRole>::Info
Source§impl<S> ServiceExt<RoleClient> for Swhere
S: Service<RoleClient>,
impl<S> ServiceExt<RoleClient> for Swhere
S: Service<RoleClient>,
fn serve_with_ct<T, E, A>( self, transport: T, ct: CancellationToken, ) -> impl Future<Output = Result<RunningService<RoleClient, S>, ClientInitializeError>> + Send
Source§fn into_dyn(self) -> Box<dyn DynService<R>>
fn into_dyn(self) -> Box<dyn DynService<R>>
Convert this service to a dynamic boxed service Read more
fn serve<T, E, A>( self, transport: T, ) -> impl Future<Output = Result<RunningService<R, Self>, <R as ServiceRole>::InitializeError>> + Send
Source§impl ServiceRole for RoleClient
impl ServiceRole for RoleClient
const IS_CLIENT: bool = true
type Req = ClientRequest
type Resp = ClientResult
type Not = ClientNotification
type PeerReq = ServerRequest
type PeerResp = ServerResult
type PeerNot = ServerNotification
type Info = InitializeRequestParam
type PeerInfo = InitializeResult
type InitializeError = ClientInitializeError
Source§impl<C> Transport<RoleClient> for SseClientTransport<C>where
C: SseClient,
impl<C> Transport<RoleClient> for SseClientTransport<C>where
C: SseClient,
type Error = SseTransportError<<C as SseClient>::Error>
Source§async fn receive(
&mut self,
) -> Option<JsonRpcMessage<ServerRequest, ServerResult, ServerNotification>>
async fn receive( &mut self, ) -> Option<JsonRpcMessage<ServerRequest, ServerResult, ServerNotification>>
Receive a message from the transport, this operation is sequential.
Source§fn send(
&mut self,
item: JsonRpcMessage<<RoleClient as ServiceRole>::Req, <RoleClient as ServiceRole>::Resp, <RoleClient as ServiceRole>::Not>,
) -> impl Future<Output = Result<(), <SseClientTransport<C> as Transport<RoleClient>>::Error>> + Send + 'static
fn send( &mut self, item: JsonRpcMessage<<RoleClient as ServiceRole>::Req, <RoleClient as ServiceRole>::Resp, <RoleClient as ServiceRole>::Not>, ) -> impl Future<Output = Result<(), <SseClientTransport<C> as Transport<RoleClient>>::Error>> + Send + 'static
Send a message to the transport Read more
Source§async fn close(
&mut self,
) -> Result<(), <SseClientTransport<C> as Transport<RoleClient>>::Error>
async fn close( &mut self, ) -> Result<(), <SseClientTransport<C> as Transport<RoleClient>>::Error>
Close the transport
fn name() -> Cow<'static, str>
Source§impl Transport<RoleClient> for TokioChildProcess
impl Transport<RoleClient> for TokioChildProcess
type Error = Error
Source§fn send(
&mut self,
item: JsonRpcMessage<<RoleClient as ServiceRole>::Req, <RoleClient as ServiceRole>::Resp, <RoleClient as ServiceRole>::Not>,
) -> impl Future<Output = Result<(), <TokioChildProcess as Transport<RoleClient>>::Error>> + Send + 'static
fn send( &mut self, item: JsonRpcMessage<<RoleClient as ServiceRole>::Req, <RoleClient as ServiceRole>::Resp, <RoleClient as ServiceRole>::Not>, ) -> impl Future<Output = Result<(), <TokioChildProcess as Transport<RoleClient>>::Error>> + Send + 'static
Send a message to the transport Read more
Source§fn receive(
&mut self,
) -> impl Future<Output = Option<JsonRpcMessage<<RoleClient as ServiceRole>::PeerReq, <RoleClient as ServiceRole>::PeerResp, <RoleClient as ServiceRole>::PeerNot>>> + Send
fn receive( &mut self, ) -> impl Future<Output = Option<JsonRpcMessage<<RoleClient as ServiceRole>::PeerReq, <RoleClient as ServiceRole>::PeerResp, <RoleClient as ServiceRole>::PeerNot>>> + Send
Receive a message from the transport, this operation is sequential.
Source§fn close(
&mut self,
) -> impl Future<Output = Result<(), <TokioChildProcess as Transport<RoleClient>>::Error>> + Send
fn close( &mut self, ) -> impl Future<Output = Result<(), <TokioChildProcess as Transport<RoleClient>>::Error>> + Send
Close the transport
fn name() -> Cow<'static, str>
impl Copy for RoleClient
impl Eq for RoleClient
impl StructuralPartialEq for RoleClient
Auto Trait Implementations§
impl Freeze for RoleClient
impl RefUnwindSafe for RoleClient
impl Send for RoleClient
impl Sync for RoleClient
impl Unpin for RoleClient
impl UnwindSafe for RoleClient
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,
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.