共用方式為


CorrelationDataMessageProperty.TryGet 方法

定義

嘗試從訊息或訊息屬性集合取得附加的 CorrelationDataMessageProperty

多載

TryGet(Message, CorrelationDataMessageProperty)

嘗試從指定訊息的 Properties 取得 CorrelationDataMessageProperty

TryGet(MessageProperties, CorrelationDataMessageProperty)

嘗試從指定訊息的屬性取得 CorrelationDataMessageProperty

TryGet(Message, CorrelationDataMessageProperty)

嘗試從指定訊息的 Properties 取得 CorrelationDataMessageProperty

public:
 static bool TryGet(System::ServiceModel::Channels::Message ^ message, [Runtime::InteropServices::Out] System::ServiceModel::Channels::CorrelationDataMessageProperty ^ % property);
public static bool TryGet (System.ServiceModel.Channels.Message message, out System.ServiceModel.Channels.CorrelationDataMessageProperty property);
static member TryGet : System.ServiceModel.Channels.Message * CorrelationDataMessageProperty -> bool
Public Shared Function TryGet (message As Message, ByRef property As CorrelationDataMessageProperty) As Boolean

參數

message
Message

包含要檢查之 Properties的訊息。

property
CorrelationDataMessageProperty

這個方法傳回時,會包括 CorrelationDataMessageProperty,其內含指定訊息的 Properties;否則為 null。 這個參數會以未初始化的狀態傳遞。

傳回

若訊息的 Properties 屬性包含 CorrelationDataMessageProperty 類別,則為 true;否則為 false

適用於

TryGet(MessageProperties, CorrelationDataMessageProperty)

嘗試從指定訊息的屬性取得 CorrelationDataMessageProperty

public:
 static bool TryGet(System::ServiceModel::Channels::MessageProperties ^ properties, [Runtime::InteropServices::Out] System::ServiceModel::Channels::CorrelationDataMessageProperty ^ % property);
public static bool TryGet (System.ServiceModel.Channels.MessageProperties properties, out System.ServiceModel.Channels.CorrelationDataMessageProperty property);
static member TryGet : System.ServiceModel.Channels.MessageProperties * CorrelationDataMessageProperty -> bool
Public Shared Function TryGet (properties As MessageProperties, ByRef property As CorrelationDataMessageProperty) As Boolean

參數

properties
MessageProperties

要檢查的訊息屬性。

property
CorrelationDataMessageProperty

這個方法傳回時,會包括指定的訊息屬性中的 CorrelationDataMessageProperty,否則為 null。 這個參數會以未初始化的狀態傳遞。

傳回

如果訊息屬性包含 CorrelationDataMessageProperty,則為 true,否則為 false

適用於