Method ReceiveMessageAsync
- Namespace
- MongoDB.Driver.Core.Connections
- Assembly
- MongoDB.Driver.Core.dll
ReceiveMessageAsync(int, IMessageEncoderSelector, MessageEncoderSettings, CancellationToken)
Receives a message.
Task<ResponseMessage> ReceiveMessageAsync(int responseTo, IMessageEncoderSelector encoderSelector, MessageEncoderSettings messageEncoderSettings, CancellationToken cancellationToken)Parameters
- responseToint
- The id of the sent message for which a response is to be received. 
- encoderSelectorIMessageEncoderSelector
- The encoder selector. 
- messageEncoderSettingsMessageEncoderSettings
- The message encoder settings. 
- cancellationTokenCancellationToken
- The cancellation token. 
Returns
- Task<ResponseMessage>
- A Task whose result is the response message.