Class VariablesRegistry

java.lang.Object
io.quarkus.qute.debug.agent.variables.VariablesRegistry

public class VariablesRegistry extends Object
Maintains a registry of all variables and variable containers (implementing VariablesProvider) in the debug session.

Each VariablesProvider is assigned a unique reference ID, which is used by the debugger client to request child variables when expanding a variable in the UI.

  • Constructor Details

    • VariablesRegistry

      public VariablesRegistry()
      Creates a new, empty registry
  • Method Details

    • addVariable

      public void addVariable(VariablesProvider variable)
      Registers a VariablesProvider and assigns it a unique variables reference ID.
      Parameters:
      variable - the provider to register
    • getVariables

      public org.eclipse.lsp4j.debug.Variable[] getVariables(int variablesReference)
      Retrieves the child variables of a registered provider given its variables reference ID.
      Parameters:
      variablesReference - the reference ID of the provider
      Returns:
      an array of Variable, or an empty array if the provider does not exist or has no variables