WebLogic Messaging API Class Library

IMessageConsumer.Receive Method (Int64)

Receives the next message that arrives within the specified timeout interval.

This call blocks until a message arrives, the timeout expires, or this message consumer is closed. A timeout of zero never expires, and the call blocks indefinitely unless connection stop() is called.

IMessage Receive(
   Int64 timeout


the timeout value (in milliseconds)

Return Value

the next message produced for this message consumer, or null if the timeout expires or this message consumer is concurrently closed, or the connection is stopped


Exception TypeCondition
MessageExceptionif JMS fails to receive the next message due to some internal error.

See Also

IMessageConsumer Interface | WebLogic.Messaging Namespace | IMessageConsumer. Overload List