pub trait ShellService:
Send
+ Sync
+ 'static {
type SubscribeReceiveStream: Stream<Item = Result<ReceiveResponse, Status>> + Send + Sync + 'static;
// Required methods
fn send<'life0, 'async_trait>(
&'life0 self,
request: Request<SendRequest>,
) -> Pin<Box<dyn Future<Output = Result<Response<SendResponse>, Status>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait;
fn subscribe_receive<'life0, 'async_trait>(
&'life0 self,
request: Request<SubscribeReceiveRequest>,
) -> Pin<Box<dyn Future<Output = Result<Response<Self::SubscribeReceiveStream>, Status>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait;
}
Expand description
Generated trait containing gRPC methods that should be implemented for use with ShellServiceServer.
Required Associated Types§
Sourcetype SubscribeReceiveStream: Stream<Item = Result<ReceiveResponse, Status>> + Send + Sync + 'static
type SubscribeReceiveStream: Stream<Item = Result<ReceiveResponse, Status>> + Send + Sync + 'static
Server streaming response type for the SubscribeReceive method.
Required Methods§
Sourcefn send<'life0, 'async_trait>(
&'life0 self,
request: Request<SendRequest>,
) -> Pin<Box<dyn Future<Output = Result<Response<SendResponse>, Status>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn send<'life0, 'async_trait>(
&'life0 self,
request: Request<SendRequest>,
) -> Pin<Box<dyn Future<Output = Result<Response<SendResponse>, Status>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Send a command line.
Sourcefn subscribe_receive<'life0, 'async_trait>(
&'life0 self,
request: Request<SubscribeReceiveRequest>,
) -> Pin<Box<dyn Future<Output = Result<Response<Self::SubscribeReceiveStream>, Status>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn subscribe_receive<'life0, 'async_trait>(
&'life0 self,
request: Request<SubscribeReceiveRequest>,
) -> Pin<Box<dyn Future<Output = Result<Response<Self::SubscribeReceiveStream>, Status>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Receive feedback from a sent command line.
This subscription needs to be made before a command line is sent, otherwise, no response will be sent.