pub trait RequestWithResponse<P>: Debug + Into<ThreadRequestResponse<P>>where
P: PoolItem,
Self::Response: Debug + From<ThreadRequestResponse<P>> + Into<ThreadRequestResponse<P>>,{
type Response;
}Expand description
This trait allows for the pairing of requests and responses
Implementing this trait for the apis request/response pairs allows the messaging infrastructure to guarantee the correctness of the messages sent and received by leveraging the type system.
Required Associated Types§
Implementors§
source§impl RequestWithResponse<Randoms> for PanicRequest
impl RequestWithResponse<Randoms> for PanicRequest
ties together the request with a response
type Response = PanicResponse
source§impl RequestWithResponse<Randoms> for MeanRequest
impl RequestWithResponse<Randoms> for MeanRequest
ties together the request with a response
type Response = MeanResponse
source§impl RequestWithResponse<Randoms> for RandomsAddRequest
impl RequestWithResponse<Randoms> for RandomsAddRequest
type Response = AddResponse
source§impl RequestWithResponse<Randoms> for SumRequest
impl RequestWithResponse<Randoms> for SumRequest
ties together the request with a response
type Response = SumResponse
source§impl<P> RequestWithResponse<RandomsBatch<P>> for RandomsBatchAddRequest<P>where
P: SenderAndReceiver<Randoms> + Send + Sync + Debug,
impl<P> RequestWithResponse<RandomsBatch<P>> for RandomsBatchAddRequest<P>where P: SenderAndReceiver<Randoms> + Send + Sync + Debug,
type Response = AddResponse
source§impl<P> RequestWithResponse<RandomsBatch<P>> for SumOfSumsRequestwhere
P: SenderAndReceiver<Randoms> + Send + Debug + Sync,
impl<P> RequestWithResponse<RandomsBatch<P>> for SumOfSumsRequestwhere P: SenderAndReceiver<Randoms> + Send + Debug + Sync,
ties together the request with a response
type Response = SumOfSumsResponse
source§impl<P> RequestWithResponse<P> for ThreadRequestResponse<P>where
P: PoolItem,
impl<P> RequestWithResponse<P> for ThreadRequestResponse<P>where P: PoolItem,
A ThreadRequestResponse is always a RequestWithResponse