MessagePropertyFilter.HashAlgorithm Propiedad

Definición

Obtiene o establece un valor que indica si se debe recuperar información de la propiedad HashAlgorithm al recibir un mensaje o leerlo.

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

Valor de propiedad

Boolean

true para recibir información de HashAlgorithm; en cualquier otro caso, false. De manera predeterminada, es false.

Atributos

Ejemplos

En el ejemplo de código siguiente se muestra el uso de la HashAlgorithm propiedad .

// Set the queue's MessageReadPropertyFilter property 
// to enable the message's HashAlgorithm property.
queue->MessageReadPropertyFilter->HashAlgorithm = 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 
// HashAlgorithm property.
Console::WriteLine("Message.HashAlgorithm: {0}", 
    orderMessage->HashAlgorithm);
// Set the queue's MessageReadPropertyFilter property to enable the
// message's HashAlgorithm property.
queue.MessageReadPropertyFilter.HashAlgorithm = 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 HashAlgorithm property.
Console.WriteLine("Message.HashAlgorithm: {0}",
    orderMessage.HashAlgorithm);

Comentarios

La HashAlgorithm propiedad de la Message clase identifica el algoritmo hash que Message Queuing usa al autenticar mensajes. El algoritmo hash también se usa al crear una firma digital para un mensaje.

Se aplica a

Consulte también