Interface TraceListener


public interface TraceListener
Listener interface for tracing the rendering process of Qute templates.

Implementations receive callbacks at key points during template rendering:

  • When a template rendering starts and ends.
  • Before and after resolving each template node (expressions, sections, etc.).

This enables logging, profiling, or building interactive debugging tools.

  • Method Details

    • onStartTemplate

      default void onStartTemplate(TemplateEvent event)
      Called when the rendering of a template starts.
      Parameters:
      event - the template event containing information about the template instance and timing
    • onBeforeResolve

      default void onBeforeResolve(ResolveEvent event)
      Called before a template node is resolved.
      Parameters:
      event - the resolve event containing the context and node to be resolved
    • onAfterResolve

      default void onAfterResolve(ResolveEvent event)
      Called after a template node has been resolved.
      Parameters:
      event - the resolve event containing the context, node, result and any error encountered
    • onEndTemplate

      default void onEndTemplate(TemplateEvent event)
      Called when the rendering of a template ends.
      Parameters:
      event - the template event containing information about the template instance and timing