Interface IDestinationResolvingMessageReceivingOperations<D>
Provides operations for receiving messages from a destination specifed as a resolvable string
Inherited Members
Namespace: Steeltoe.Messaging.Core
Assembly: Steeltoe.Messaging.Abstractions.dll
Syntax
public interface IDestinationResolvingMessageReceivingOperations<D> : IMessageReceivingOperations<D>
Type Parameters
Name | Description |
---|---|
D | the destination type |
Methods
| Edit this page View SourceReceive(String)
Resolve the given destination and receive a message from it
Declaration
IMessage Receive(string destinationName)
Parameters
Type | Name | Description |
---|---|---|
System.String | destinationName | the destination name to resolve |
Returns
Type | Description |
---|---|
IMessage | the received message |
ReceiveAndConvert<T>(String)
Resolve the given destination, receive a message from it, convert the payload to the specified target type
Declaration
T ReceiveAndConvert<T>(string destinationName)
Parameters
Type | Name | Description |
---|---|---|
System.String | destinationName | the destination name to resolve |
Returns
Type | Description |
---|---|
T | the received message |
Type Parameters
Name | Description |
---|---|
T | the target type |
ReceiveAndConvertAsync<T>(String, CancellationToken)
Resolve the given destination, receive a message from it, convert the payload to the specified target type
Declaration
Task<T> ReceiveAndConvertAsync<T>(string destinationName, CancellationToken cancellationToken = null)
Parameters
Type | Name | Description |
---|---|---|
System.String | destinationName | the destination name to resolve |
CancellationToken | cancellationToken | a token used to cancel the operation |
Returns
Type | Description |
---|---|
Task<T> | a task to signal completion |
Type Parameters
Name | Description |
---|---|
T | the target type |
ReceiveAsync(String, CancellationToken)
Resolve the given destination and receive a message from it
Declaration
Task<IMessage> ReceiveAsync(string destinationName, CancellationToken cancellationToken = null)
Parameters
Type | Name | Description |
---|---|---|
System.String | destinationName | the destination name to resolve |
CancellationToken | cancellationToken | a token used to cancel the operation |
Returns
Type | Description |
---|---|
Task<IMessage> | a task to signal completion |