Exporteren (0) Afdrukken
Alles uitvouwen
EN
Deze inhoud is niet beschikbaar in uw taal, maar wel in het Engels.

SubscriptionClient.Receive Method (TimeSpan)

Receives a message using the InternalReceiver().

Namespace:  Microsoft.ServiceBus.Messaging
Assembly:  Microsoft.ServiceBus (in Microsoft.ServiceBus.dll)

public BrokeredMessage Receive(
	TimeSpan serverWaitTime
)

Parameters

serverWaitTime
Type: System.TimeSpan
The time span the server waits for receiving a message before it times out.

Return Value

Type: Microsoft.ServiceBus.Messaging.BrokeredMessage
The BrokeredMessage that represents the received message.

ExceptionCondition
ArgumentOutOfRangeException

Thrown if the serverWaitTime is negative.

MessagingEntityNotFoundException

Thrown when the subscription does not exist.

OperationCanceledException

Thrown if the client entity has been closed or aborted.

TimeoutException

Thrown if the operation exceeded the timeout value set via OperationTimeout.

UnauthorizedAccessException

Thrown if there is an authentication error.

If Zero is passed in serverWaitTime, then there will be no wait time. Instead server bus will fetch whatever messages are immediately available, or return null as a result.

Community-inhoud

Toevoegen
Weergeven:
© 2014 Microsoft