Record Class LimitsSectionSpigot.Result

java.lang.Object
java.lang.Record
nl.pim16aap2.animatedarchitecture.spigot.core.config.LimitsSectionSpigot.Result
Record Components:
maxStructureCount - The maximum number of structures a player can have.
maxBlocksToMove - The maximum number of blocks that can be moved in a single animation.
maxStructureSize - The maximum size of a structure in terms of blocks.
maxPowerblockDistance - The maximum distance between power blocks in a structure.
maxBlockSpeed - The maximum speed at which blocks can move in an animation.
All Implemented Interfaces:
IConfigSectionResult
Enclosing class:
LimitsSectionSpigot

public static record LimitsSectionSpigot.Result(OptionalInt maxStructureCount, OptionalInt maxBlocksToMove, OptionalInt maxStructureSize, OptionalInt maxPowerblockDistance, OptionalDouble maxBlockSpeed) extends Record implements IConfigSectionResult
Represents the result of the LimitsSectionSpigot configuration.
  • Field Details

  • Constructor Details

    • Result

      public Result(int maxStructureCount, int maxBlocksToMove, int maxStructureSize, int maxPowerblockDistance, double maxBlockSpeed)
    • Result

      public Result(OptionalInt maxStructureCount, OptionalInt maxBlocksToMove, OptionalInt maxStructureSize, OptionalInt maxPowerblockDistance, OptionalDouble maxBlockSpeed)
      Creates an instance of a Result record class.
      Parameters:
      maxStructureCount - the value for the maxStructureCount record component
      maxBlocksToMove - the value for the maxBlocksToMove record component
      maxStructureSize - the value for the maxStructureSize record component
      maxPowerblockDistance - the value for the maxPowerblockDistance record component
      maxBlockSpeed - the value for the maxBlockSpeed record component
  • Method Details

    • toString

      public final 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
    • 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. All components in this record class are compared with Objects::equals(Object,Object).
      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.
    • maxStructureCount

      public OptionalInt maxStructureCount()
      Returns the value of the maxStructureCount record component.
      Returns:
      the value of the maxStructureCount record component
    • maxBlocksToMove

      public OptionalInt maxBlocksToMove()
      Returns the value of the maxBlocksToMove record component.
      Returns:
      the value of the maxBlocksToMove record component
    • maxStructureSize

      public OptionalInt maxStructureSize()
      Returns the value of the maxStructureSize record component.
      Returns:
      the value of the maxStructureSize record component
    • maxPowerblockDistance

      public OptionalInt maxPowerblockDistance()
      Returns the value of the maxPowerblockDistance record component.
      Returns:
      the value of the maxPowerblockDistance record component
    • maxBlockSpeed

      public OptionalDouble maxBlockSpeed()
      Returns the value of the maxBlockSpeed record component.
      Returns:
      the value of the maxBlockSpeed record component