Message.InfiniteTimeout 欄位

定義

指定沒有逾時。Specifies that no time-out exists.

public: static initonly TimeSpan InfiniteTimeout;
public static readonly TimeSpan InfiniteTimeout;
 staticval mutable InfiniteTimeout : TimeSpan
Public Shared ReadOnly InfiniteTimeout As TimeSpan 

欄位值

TimeSpan

範例

下列程式碼範例將示範如何使用 InfiniteTimeout 欄位。The following code example demonstrates the use of the InfiniteTimeout field.

備註

TimeToBeReceivedTimeToReachQueue 需要指定超時時間的值。若是前者,超時時間是允許從佇列接收訊息的最長時間。TimeToBeReceived and TimeToReachQueue require a value that specifies a time-out. For the former, the time-out is the maximum time allowed for a message to be received from the queue. 若是後者,則時間是訊息抵達佇列所允許的時間。For the latter, the time-out is the time allowed for a message to reach the queue. 在這兩種情況下,您可以將超時時間指定為秒數,或用 InfiniteTimeout 來指出沒有超時時間。In both cases, you can specify the time-out as a number of seconds or use InfiniteTimeout to indicate that no time-out exists.

適用於

另請參閱