语言

ContextMessageProperty.TryGet 方法

定义

尝试从指定的消息或消息属性集合中获取 ContextMessageProperty 。

重载

名称 说明
TryGet(Message, ContextMessageProperty)

尝试从指定消息的属性中获取 ContextMessageProperty 。

TryGet(MessageProperties, ContextMessageProperty)

尝试从指定的消息属性集合中获取 ContextMessageProperty 消息属性。

TryGet(Message, ContextMessageProperty)

尝试从指定消息的属性中获取 ContextMessageProperty 。

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

参数

message
Message

Message要从中检索上下文消息属性的上下文消息属性。

contextMessageProperty
ContextMessageProperty

此方法返回时,包含一个包含与 <a0/a0> 关联的项。 此参数未初始化传递。

返回

如果从 <a0/&a0; 获取值,则为 /&;。

适用于

TryGet(MessageProperties, ContextMessageProperty)

尝试从指定的消息属性集合中获取 ContextMessageProperty 消息属性。

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

参数

properties
MessageProperties

MessageProperties要从中检索上下文消息属性的上下文消息属性。

contextMessageProperty
ContextMessageProperty

此方法返回时,包含一个包含与 <a0/a0> 关联的项。 此参数未初始化传递。

返回

如果从 <a0/&a0; 获取值,则为 /&;。

适用于