SerializedMessagePayloadFeatureExtensions.GetSerializedPayload<T> Method
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.
Gets the message payload as a serialized T
type.
public:
generic <typename T>
[System::Runtime::CompilerServices::Extension]
static T GetSerializedPayload(System::Cloud::Messaging::MessageContext ^ context);
public static T GetSerializedPayload<T>(this System.Cloud.Messaging.MessageContext context);
static member GetSerializedPayload : System.Cloud.Messaging.MessageContext -> 'T
<Extension()>
Public Function GetSerializedPayload(Of T) (context As MessageContext) As T
Type Parameters
- T
Type of the serialized message payload.
Parameters
- context
- MessageContext
The message context.
Returns
T
The serialized message payload.
Exceptions
context
is null
.
No ISerializedMessagePayloadFeature<T> is set in the context
.
Remarks
Ensure the serialized message payload is set in the pipeline via SetSerializedPayload<T>(MessageContext, T) before calling this method.
Applies to
GitHub で Microsoft と共同作業する
このコンテンツのソースは GitHub にあります。そこで、issue や pull request を作成および確認することもできます。 詳細については、共同作成者ガイドを参照してください。
.NET