TheCommRequestResponse..::..PublishRequestJSonAsync<(Of <(<'inputT, outputT>)>)> Method (TheMessageAddress, inputT, TimeSpan)
Sends a message with JSON-serialized parameters to the targetThing and returns the response message as a deserialized object
Namespace:
nsCDEngine.CommunicationAssembly: C-DEngine (in C-DEngine.dll)
Syntax
public static Task<outputT> PublishRequestJSonAsync<inputT, outputT>( TheMessageAddress target, inputT messageParameters, TimeSpan timeout )
Public Shared Function PublishRequestJSonAsync(Of inputT, outputT) ( _ target As TheMessageAddress, _ messageParameters As inputT, _ timeout As TimeSpan _ ) As Task(Of outputT)
public: generic<typename inputT, typename outputT> static Task<outputT>^ PublishRequestJSonAsync( TheMessageAddress^ target, inputT messageParameters, TimeSpan^ timeout )
Type Parameters
- inputT
- outputT
Parameters
- target
- Type: nsCDEngine.Communication..::..TheMessageAddress
Thing or engine to which the message is to be sent.
- messageParameters
- Type: inputT
The object to send as the payload of the message.
- timeout
- Type: TimeSpan
If the response message is not returned within this time, the result of the Task will be set to null.