Class DebuggerTraceListener

java.lang.Object
io.quarkus.qute.debug.agent.DebuggerTraceListener
All Implemented Interfaces:
io.quarkus.qute.trace.TraceListener

public class DebuggerTraceListener extends Object implements io.quarkus.qute.trace.TraceListener
A TraceListener implementation that connects the Qute engine's trace events to the DebuggeeAgent.

This listener is responsible for intercepting template execution events and forwarding them to the debugger agent so that they can be processed for debugging purposes (breakpoints, stepping, etc.).

  • Constructor Details

    • DebuggerTraceListener

      public DebuggerTraceListener(DebuggeeAgent agent)
      Creates a new trace listener for the given debugger agent.
      Parameters:
      agent - the DebuggeeAgent that will receive the traced events, must not be null
  • Method Details

    • onBeforeResolve

      public void onBeforeResolve(io.quarkus.qute.trace.ResolveEvent event)
      Called before a template node is resolved.

      This method is invoked for every template node about to be processed, and it forwards the event to the DebuggeeAgent so that it can handle breakpoints and stepping at a fine-grained level.

      Specified by:
      onBeforeResolve in interface io.quarkus.qute.trace.TraceListener
      Parameters:
      event - the resolve event triggered by the Qute engine
    • onAfterResolve

      public void onAfterResolve(io.quarkus.qute.trace.ResolveEvent event)
      Specified by:
      onAfterResolve in interface io.quarkus.qute.trace.TraceListener
    • onStartTemplate

      public void onStartTemplate(io.quarkus.qute.trace.TemplateEvent event)
      Called when the rendering of a template starts.

      This event signals the beginning of template execution and allows the debugger to create and track a new debuggee thread.

      Specified by:
      onStartTemplate in interface io.quarkus.qute.trace.TraceListener
      Parameters:
      event - the template start event
    • onEndTemplate

      public void onEndTemplate(io.quarkus.qute.trace.TemplateEvent event)
      Called when the rendering of a template ends.

      This event signals that the template execution has completed, allowing the debugger to clean up resources associated with the thread.

      Specified by:
      onEndTemplate in interface io.quarkus.qute.trace.TraceListener
      Parameters:
      event - the template end event