Class InterpreterManager
java.lang.Object
io.github.toberocat.guiengine.interpreter.InterpreterManager
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 Summary
ConstructorsConstructorDescriptionCreates a new InterpreterManager with an empty interpreter map. -
Method Summary
Modifier and TypeMethodDescription@Nullable GuiInterpreter
getInterpreter
(@NotNull String interpreter) Retrieves the GuiInterpreter associated with the given interpreter ID.void
registerInterpreter
(@NotNull GuiInterpreter interpreter) Registers a new GuiInterpreter in the manager.
-
Constructor Details
-
InterpreterManager
public InterpreterManager()Creates a new InterpreterManager with an empty interpreter map.
-
-
Method Details
-
getInterpreter
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
Registers a new GuiInterpreter in the manager.- Parameters:
interpreter
- The GuiInterpreter instance to be registered.
-