SendMessageContent Class
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
public ref class SendMessageContent sealed : System::ServiceModel::Activities::SendContent
[System.Windows.Markup.ContentProperty("Message")]
public sealed class SendMessageContent : System.ServiceModel.Activities.SendContent
[<System.Windows.Markup.ContentProperty("Message")>]
type SendMessageContent = class
inherit SendContent
Public NotInheritable Class SendMessageContent
Inherits SendContent
- Inheritance
- Attributes
Examples
The following example shows how to use a SendMessageContent instance with a Send activity.
Variable<PurchaseOrder> po = new Variable<PurchaseOrder>();
Variable<Customer> customer = new Variable<Customer>();
Endpoint clientEndpoint = new Endpoint
{
Binding = Constants.Binding,
AddressUri = new Uri(Constants.ServiceAddress)
};
Send submitPO = new Send
{
Endpoint = clientEndpoint,
ServiceContractName = Constants.POContractName,
OperationName = Constants.SubmitPOName,
Content = new SendMessageContent(new InArgument<PurchaseOrder>(po))
};
Remarks
When using this class, messages serialized on the wire are unwrapped, unless the data is a message contract type or of type Message.
Constructors
SendMessageContent() |
Initializes a new instance of the SendMessageContent class. |
SendMessageContent(InArgument) |
Initializes a new instance of the SendMessageContent class with the specified data to send. |
SendMessageContent(InArgument, Type) |
Initializes a new instance of the SendMessageContent class with the specified message and message type. |
Properties
DeclaredMessageType |
Gets or sets the declared message type. |
Message |
Gets or sets the data to send. |
Methods
Equals(Object) |
Determines whether the specified object is equal to the current object. (Inherited from Object) |
GetHashCode() |
Serves as the default hash function. (Inherited from Object) |
GetType() |
Gets the Type of the current instance. (Inherited from Object) |
MemberwiseClone() |
Creates a shallow copy of the current Object. (Inherited from Object) |
ShouldSerializeDeclaredMessageType() |
Gets a value that indicates whether the DeclaredMessageType property should be XAML-serialized. |
ToString() |
Returns a string that represents the current object. (Inherited from Object) |
Applies to
反馈
https://aka.ms/ContentUserFeedback。
即将发布:在整个 2024 年,我们将逐步淘汰作为内容反馈机制的“GitHub 问题”,并将其取代为新的反馈系统。 有关详细信息,请参阅:提交和查看相关反馈