TTMSMCPTransport.SendRequestToSession Method
Tries to push a server-initiated request to one session over whatever live channel is open for it.
API unit family: TMS.MCP.Transport
Declaring type: TTMSMCPTransport
Syntax
function SendRequestToSession(const ASessionId, ARequestJson: string): Boolean; virtual;
Remarks
A False result means delivery is not possible and the caller must fall back rather than wait for a reply. The reply to a request that was handed off arrives later through the normal inbound message path and is correlated by the request id, not returned here. This class always returns False; a channel that can reach a specific client on demand overrides it.
Parameters
| Name | Description |
|---|---|
ASessionId |
Session to deliver the request to. |
ARequestJson |
Request text to send, normally a JSON-RPC request carrying an id. |
Returns
True when the channel was able to hand the message off, False when there is no live channel to that session - either because the channel has no sessions at all, or because no stream is currently open for this one.