Record Class Zone

java.lang.Object
java.lang.Record
com.hypixel.hytale.server.worldgen.zone.Zone

public record Zone(int id, String name, @Nonnull ZoneDiscoveryConfig discoveryConfig, @Nullable CaveGenerator caveGenerator, @Nonnull BiomePatternGenerator biomePatternGenerator, @Nonnull UniquePrefabContainer uniquePrefabContainer) extends Record
  • Field Details

    • id

      private final int id
      The field for the id record component.
    • name

      private final String name
      The field for the name record component.
    • discoveryConfig

      @Nonnull private final ZoneDiscoveryConfig discoveryConfig
      The field for the discoveryConfig record component.
    • caveGenerator

      @Nullable private final CaveGenerator caveGenerator
      The field for the caveGenerator record component.
    • biomePatternGenerator

      @Nonnull private final BiomePatternGenerator biomePatternGenerator
      The field for the biomePatternGenerator record component.
    • uniquePrefabContainer

      @Nonnull private final UniquePrefabContainer uniquePrefabContainer
      The field for the uniquePrefabContainer record component.
  • Constructor Details

    • Zone

      public Zone(int id, String name, @Nonnull ZoneDiscoveryConfig discoveryConfig, @Nullable CaveGenerator caveGenerator, @Nonnull BiomePatternGenerator biomePatternGenerator, @Nonnull UniquePrefabContainer uniquePrefabContainer)
      Creates an instance of a Zone record class.
      Parameters:
      id - the value for the id record component
      name - the value for the name record component
      discoveryConfig - the value for the discoveryConfig record component
      caveGenerator - the value for the caveGenerator record component
      biomePatternGenerator - the value for the biomePatternGenerator record component
      uniquePrefabContainer - the value for the uniquePrefabContainer record component
  • Method Details

    • hashCode

      public int hashCode()
      Returns a hash code value for this object. The value is derived from the hash code of each of the record components.
      Specified by:
      hashCode in class Record
      Returns:
      a hash code value for this object
    • toString

      @Nonnull public String toString()
      Returns a string representation of this record class. The representation contains the name of the class, followed by the name and value of each of the record components.
      Specified by:
      toString in class Record
      Returns:
      a string representation of this object
    • equals

      public final boolean equals(Object o)
      Indicates whether some other object is "equal to" this one. The objects are equal if the other object is of the same class and if all the record components are equal. Reference components are compared with Objects::equals(Object,Object); primitive components are compared with '=='.
      Specified by:
      equals in class Record
      Parameters:
      o - the object with which to compare
      Returns:
      true if this object is the same as the o argument; false otherwise.
    • id

      public int id()
      Returns the value of the id record component.
      Returns:
      the value of the id record component
    • name

      public String name()
      Returns the value of the name record component.
      Returns:
      the value of the name record component
    • discoveryConfig

      @Nonnull public ZoneDiscoveryConfig discoveryConfig()
      Returns the value of the discoveryConfig record component.
      Returns:
      the value of the discoveryConfig record component
    • caveGenerator

      @Nullable public CaveGenerator caveGenerator()
      Returns the value of the caveGenerator record component.
      Returns:
      the value of the caveGenerator record component
    • biomePatternGenerator

      @Nonnull public BiomePatternGenerator biomePatternGenerator()
      Returns the value of the biomePatternGenerator record component.
      Returns:
      the value of the biomePatternGenerator record component
    • uniquePrefabContainer

      @Nonnull public UniquePrefabContainer uniquePrefabContainer()
      Returns the value of the uniquePrefabContainer record component.
      Returns:
      the value of the uniquePrefabContainer record component