Class InterpreterManager

java.lang.Object
io.github.toberocat.guiengine.interpreter.InterpreterManager

public class InterpreterManager extends Object
This class represents the InterpreterManager, responsible for managing and providing access to various implementations of the GuiInterpreter interface.

Created: 04/02/2023

Author:
Tobias Madlberger (Tobias)
  • Constructor Details

    • InterpreterManager

      public InterpreterManager()
      Creates a new InterpreterManager with an empty interpreter map.
  • Method Details

    • getInterpreter

      @Nullable public @Nullable GuiInterpreter getInterpreter(@NotNull @NotNull String interpreter)
      Retrieves the GuiInterpreter associated with the given interpreter ID.
      Parameters:
      interpreter - The ID of the GuiInterpreter to retrieve.
      Returns:
      The corresponding GuiInterpreter instance if found, or null if not present in the manager.
    • registerInterpreter

      public void registerInterpreter(@NotNull @NotNull GuiInterpreter interpreter)
      Registers a new GuiInterpreter in the manager.
      Parameters:
      interpreter - The GuiInterpreter instance to be registered.