Class PlaceholderCatalog

java.lang.Object
de.Keyle.MyPet.api.gui.PlaceholderCatalog

public final class PlaceholderCatalog extends Object
Mutable carrier for the TagResolvers a section renderer assembles per rendered item. Renderers add named placeholders here; the renderer then runs MiniMessage with the resolvers in scope.
  • Constructor Details

    • PlaceholderCatalog

      public PlaceholderCatalog()
      Creates an empty catalog.
  • Method Details

    • add

      public PlaceholderCatalog add(TagResolver resolver)
      Adds a resolver to this catalog.
      Parameters:
      resolver - the resolver to add
      Returns:
      this catalog, for chaining
    • build

      public TagResolver build()
      Combines everything added so far into one resolver.
      Returns:
      the combined resolver, or an empty one if nothing was added