MessageDescription Class
Represents the description of a message.
Assembly: System.ServiceModel (in System.ServiceModel.dll)
| Name | Description | |
|---|---|---|
![]() | MessageDescription(String^, MessageDirection) | Initializes a new instance of the MessageDescription class with a specified action and direction. |
| Name | Description | |
|---|---|---|
![]() | Action | Gets or sets the action parameter of the SOAP message that identifies the intent of the message. |
![]() | Body | Gets the body of the SOAP message. |
![]() | Direction | Gets the direction that indicates whether the message is incoming or outgoing. |
![]() | HasProtectionLevel | Gets a value that indicates whether the ProtectionLevel has been set. |
![]() | Headers | Gets the description of the headers of the SOAP message. |
![]() | MessageType | Gets or sets a type that identifies the type of message contract. |
![]() | Properties | Gets a description of the properties of the SOAP message. |
![]() | ProtectionLevel | Gets or sets the security services required for the message. |
| Name | Description | |
|---|---|---|
![]() | Equals(Object^) | Determines whether the specified object is equal to the current object.(Inherited from Object.) |
![]() | Finalize() | Allows an object to try to free resources and perform other cleanup operations before it is reclaimed by garbage collection.(Inherited from Object.) |
![]() | GetHashCode() | Serves as the default hash function. (Inherited from Object.) |
![]() | GetType() | |
![]() | MemberwiseClone() | |
![]() | ShouldSerializeProtectionLevel() | Returns a value that indicates whether the ProtectionLevel property has changed from its default value and should be serialized. |
![]() | ToString() | Returns a string that represents the current object.(Inherited from Object.) |
The MessageDescription contains the Headers and Body properties to provide get access to these parts of the message. Whether the message is incoming or outgoing is indicated by the Direction property. It also provides an Action property where the URI that indicates the intension of the message may be specified.
The following example uses the MessageDescription returned from Messages property of the OperationDescription class. The code iterates through the collection of endpoints and prints each endpoint name, as well as the name of each operation in the endpoint.
Available since 8
.NET Framework
Available since 3.0
Portable Class Library
Supported in: portable .NET platforms
Silverlight
Available since 2.0
Windows Phone Silverlight
Available since 7.0
Any public static ( Shared in Visual Basic) members of this type are thread safe. Any instance members are not guaranteed to be thread safe.


