TsgcWSPClient_AMQP1 › Methods › WriteData
Low-level method that writes raw bytes straight onto the underlying WebSocket / broker transport, bypassing the AMQP 1.0 codec. Overloaded for string or stream input.
procedure WriteData(const aText: String);
| Name | Type | Description |
|---|---|---|
aText | const String | Raw text pushed onto the transport without any AMQP 1.0 framing. |
String overload. The text is written as a single WebSocket text frame (or a raw TCP write when using the Broker transport) without passing through the AMQP 1.0 frame codec — no Open/Begin/Attach/Transfer wrapper is added. Intended for diagnostics, testing of malformed frames and advanced integration only; regular messaging should use the link-level methods.
oAMQP1.WriteData('raw diagnostic frame');
procedure WriteData(aStream: TStream; aSize: Integer = 0; const aStreaming: TwsStreaming = stmNone);
| Name | Type | Description |
|---|---|---|
aStream | TStream | Stream whose bytes are written directly as one or more binary WebSocket frames. This is the path the internal codec uses to emit Open / Begin / Attach / Transfer / Detach / End / Close frames. |
aSize | Integer | Number of bytes to read from aStream; 0 means the full stream. |
aStreaming | const TwsStreaming | WebSocket streaming mode used when a large payload must be split across multiple frames (stmNone writes a single frame). |
Stream overload. Sends the stream content as binary frames without re-encoding it at the AMQP 1.0 layer, so the buffer must already be a valid sequence of framed AMQP 1.0 performatives. This is the primitive the component itself uses internally after encoding a frame; application code normally only needs it for manual injection tests or to forward captured traffic.
oAMQP1.WriteData(vStream, 0, stmNone);