Record Class StructureTemplate.JigsawBlockInfo

java.lang.Object
java.lang.Record
net.minecraft.world.level.levelgen.structure.templatesystem.StructureTemplate.JigsawBlockInfo
Enclosing class:
StructureTemplate

public static record StructureTemplate.JigsawBlockInfo(StructureTemplate.StructureBlockInfo info, JigsawBlockEntity.JointType jointType, ResourceLocation name, ResourceKey<StructureTemplatePool> pool, ResourceLocation target, int placementPriority, int selectionPriority) extends Record
  • Field Details

    • info

      The field for the info record component.
    • jointType

      private final JigsawBlockEntity.JointType jointType
      The field for the jointType record component.
    • name

      private final ResourceLocation name
      The field for the name record component.
    • pool

      private final ResourceKey<StructureTemplatePool> pool
      The field for the pool record component.
    • target

      private final ResourceLocation target
      The field for the target record component.
    • placementPriority

      private final int placementPriority
      The field for the placementPriority record component.
    • selectionPriority

      private final int selectionPriority
      The field for the selectionPriority record component.
  • Constructor Details

    • JigsawBlockInfo

      public JigsawBlockInfo(StructureTemplate.StructureBlockInfo info, JigsawBlockEntity.JointType jointType, ResourceLocation name, ResourceKey<StructureTemplatePool> pool, ResourceLocation target, int placementPriority, int selectionPriority)
      Creates an instance of a JigsawBlockInfo record class.
      Parameters:
      info - the value for the info record component
      jointType - the value for the jointType record component
      name - the value for the name record component
      pool - the value for the pool record component
      target - the value for the target record component
      placementPriority - the value for the placementPriority record component
      selectionPriority - the value for the selectionPriority record component
  • Method Details

    • of

    • toString

      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
    • withInfo

    • hashCode

      public final 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
    • 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.
    • info

      Returns the value of the info record component.
      Returns:
      the value of the info record component
    • jointType

      public JigsawBlockEntity.JointType jointType()
      Returns the value of the jointType record component.
      Returns:
      the value of the jointType record component
    • name

      public ResourceLocation name()
      Returns the value of the name record component.
      Returns:
      the value of the name record component
    • pool

      Returns the value of the pool record component.
      Returns:
      the value of the pool record component
    • target

      public ResourceLocation target()
      Returns the value of the target record component.
      Returns:
      the value of the target record component
    • placementPriority

      public int placementPriority()
      Returns the value of the placementPriority record component.
      Returns:
      the value of the placementPriority record component
    • selectionPriority

      public int selectionPriority()
      Returns the value of the selectionPriority record component.
      Returns:
      the value of the selectionPriority record component