Interface Holders


@NonExtendable public interface Holders
Similar to the HolderSets in Minecraft, a Holders object can represent either a list of identifiers, or an identifier of a Minecraft registry tag. What these identifiers represent depends on the context in which Holders are used.
Since:
2.9.3
  • Nested Class Summary

    Nested Classes
    Modifier and Type
    Interface
    Description
    static interface 
    Builder for the Holders object
  • Method Summary

    Static Methods
    Modifier and Type
    Method
    Description
    static @NonNull Holders.Builder
    Creates a builder for a Holders object.
    static @NonNull Holders
    of(List<Identifier> identifiers)
    Creates a Holders object consisting of a list of identifiers.
    static @NonNull Holders
    of(Identifier identifier)
    Creates a Holders object consisting of a single identifier.
    static @NonNull Holders
    Creates a Holders object consisting of a tag
  • Method Details

    • of

      static @NonNull Holders of(Identifier identifier)
      Creates a Holders object consisting of a single identifier.
      Parameters:
      identifier - the identifier the Holders object consists of
      Returns:
      a new Holders object
      Since:
      2.9.3
    • of

      static @NonNull Holders of(List<Identifier> identifiers)
      Creates a Holders object consisting of a list of identifiers.
      Parameters:
      identifiers - the identifiers the Holders object consists of
      Returns:
      a new Holders object
      Since:
      2.9.3
    • ofTag

      static @NonNull Holders ofTag(Identifier tag)
      Creates a Holders object consisting of a tag
      Parameters:
      tag - the tag the Holders object consists of
      Returns:
      a new Holders object
      Since:
      2.9.3
    • builder

      static @NonNull Holders.Builder builder()
      Creates a builder for a Holders object.
      Returns:
      a new builder
      Since:
      2.9.3