TsgcWSPClient_AMQP1 › Events › OnAMQPBeforeReadFrame
Fires for every AMQP 1.0 frame received from the peer before the component dispatches it, allowing inspection or suppression.
property OnAMQPBeforeReadFrame: TsgcAMQP1BeforeReadFrameEvent;
// TsgcAMQP1BeforeReadFrameEvent = procedure(Sender: TObject; const aFrame: TsgcAMQP1Frame; var Handled: Boolean) of object
—
Low-level hook for protocol tracing and frame manipulation. aFrame is the decoded frame (Open / Begin / Attach / Flow / Transfer / Disposition / Detach / End / Close / SASL*) with its performative and optional payload populated. Set Handled := True to stop the default dispatch — useful when the application takes over processing, drops a specific performative or wants to inject a synthetic response. Leave Handled unchanged for a passive tap (logging, metrics). Runs on the reader thread.
procedure TForm1.oAMQP1AMQPBeforeReadFrame(Sender: TObject;
const aFrame: TsgcAMQP1Frame; var Handled: Boolean);
begin
DoLog('#AMQP1 in: ' + aFrame.ClassName);
end;