Spring.NET 1.3.0 RC1 for .NET 2.0 API Reference

EmsTemplate.ReceiveSelectedAndConvert(String, String) Method

Receive a message synchronously from the specified destination, but only wait up to a specified time for delivery. Convert the message into an object with a configured IMessageConverter.

This method should be used carefully, since it will block the thread until the message becomes available or until the timeout value is exceeded.

[Visual Basic]
Public NotOverridable Overloads Sub ReceiveSelectedAndConvert( _
   ByVal destinationName As String, _
   ByVal messageSelector As String _
) _
    Implements IEmsOperations.ReceiveSelectedAndConvert
[C#]
public object ReceiveSelectedAndConvert(
   string destinationName,
   string messageSelector
);

Parameters

destinationName
the name of the destination to send this message to (to be resolved to an actual destination by a DestinationResolver)
messageSelector
the EMS message selector expression (or
null
if none). See the EMS specification for a detailed definition of selector expressions.

Return Value

the message produced for the consumer or

null
if the timeout expires.

Implements

IEmsOperations.ReceiveSelectedAndConvert

Exceptions

Exception TypeCondition
EMSExceptionIf there is any problem accessing the EMS API

See Also

EmsTemplate Class | Spring.Messaging.Ems.Core Namespace | EmsTemplate.ReceiveSelectedAndConvert Overload List