MessagePropertyFilter.DestinationQueue Eigenschaft

Definition

Ruft einen Wert ab, der angibt, ob beim Einsehen oder beim Empfang einer Meldung die DestinationQueue-Eigenschaft abgerufen wird, oder legt diesen fest.

public:
 property bool DestinationQueue { bool get(); void set(bool value); };
[System.Messaging.MessagingDescription("MsgDestinationQueue")]
public bool DestinationQueue { get; set; }
[<System.Messaging.MessagingDescription("MsgDestinationQueue")>]
member this.DestinationQueue : bool with get, set
Public Property DestinationQueue As Boolean

Eigenschaftswert

true, wenn Informationen über den DestinationQueue abgerufen werden, andernfalls false. Der Standardwert ist false.

Attribute

Beispiele

Im folgenden Codebeispiel wird die Verwendung des DestinationQueue-Attributs veranschaulicht.

// Set the queue's MessageReadPropertyFilter property 
// to enable the message's DestinationQueue property.
queue->MessageReadPropertyFilter->
    DestinationQueue = true;

// Peek at the message. Time out after ten seconds 
// in case the message was not delivered.
orderMessage = queue->Peek(TimeSpan::FromSeconds(10.0));

// Display the value of the message's 
// Destinationqueue->QueueName property.
Console::WriteLine(
    "Message.Destinationqueue->QueueName: {0}", 
    orderMessage->DestinationQueue->QueueName);
// Set the queue's MessageReadPropertyFilter property to enable the
// message's DestinationQueue property.
queue.MessageReadPropertyFilter.DestinationQueue = true;

// Peek at the message. Time out after ten seconds in case the message
// was not delivered.
orderMessage = queue.Peek(TimeSpan.FromSeconds(10.0));

// Display the value of the message's DestinationQueue.QueueName
// property.
Console.WriteLine("Message.DestinationQueue.QueueName: {0}",
    orderMessage.DestinationQueue.QueueName);

Hinweise

Die DestinationQueue -Eigenschaft der Message -Klasse identifiziert die ursprüngliche Zielwarteschlange der Nachricht. Sie wird in der Regel verwendet, um das ursprüngliche Ziel einer Nachricht zu bestimmen, die sich in einer Journal- oder Unzustellbare Warteschlange befindet. Es kann auch verwendet werden, wenn eine Antwortnachricht zurück an eine Antwortwarteschlange gesendet wird.

Gilt für:

Weitere Informationen