Table of Contents

Class ResponseSubscription<TRequest, TResponse>

Namespace
CarrotMQ.Core.Handlers
Assembly
CarrotMQ.Core.dll

Represents a subscription to a CarrotMQ response CarrotResponse<TRequest, TResponse>

public class ResponseSubscription<TRequest, TResponse> where TRequest : _IRequest<TRequest, TResponse> where TResponse : class

Type Parameters

TRequest

The type of the original request that generated this response.

TResponse

The type of the response.

Inheritance
ResponseSubscription<TRequest, TResponse>
Inherited Members

Remarks

You can register this subscription with AddResponseSubscription<TRequest, TResponse>() when configuring the DI.

Constructors

ResponseSubscription(ILogger<ResponseSubscription<TRequest, TResponse>>)

public ResponseSubscription(ILogger<ResponseSubscription<TRequest, TResponse>> logger)

Parameters

logger ILogger<ResponseSubscription<TRequest, TResponse>>

Fields

ResponseReceived

An event handler that is invoked when a CarrotMQ response of type CarrotResponse<TRequest, TResponse>> is received.

public AsyncEventHandler<ResponseSubscriptionEventArgs<TRequest, TResponse>>? ResponseReceived

Field Value

AsyncEventHandler<ResponseSubscriptionEventArgs<TRequest, TResponse>>