Record Class TownySettings.TownLevel

java.lang.Object
java.lang.Record
com.palmergames.bukkit.towny.TownySettings.TownLevel
Enclosing class:
TownySettings

public static record TownySettings.TownLevel(String namePrefix, String namePostfix, String mayorPrefix, String mayorPostfix, int townBlockLimit, double upkeepModifier, double peacefulCostMultiplier, int townOutpostLimit, int townBlockBuyBonusLimit, double debtCapModifier, double resourceProductionModifier, double bankCapModifier, Map<String,Integer> townBlockTypeLimits) extends Record
  • Constructor Summary

    Constructors
    Constructor
    Description
    TownLevel(String namePrefix, String namePostfix, String mayorPrefix, String mayorPostfix, int townBlockLimit, double upkeepModifier, double peacefulCostMultiplier, int townOutpostLimit, int townBlockBuyBonusLimit, double debtCapModifier, double resourceProductionModifier, double bankCapModifier, Map<String,Integer> townBlockTypeLimits)
    Creates an instance of a TownLevel record class.
  • Method Summary

    Modifier and Type
    Method
    Description
    double
    Returns the value of the bankCapModifier record component.
    double
    Returns the value of the debtCapModifier record component.
    final boolean
    Indicates whether some other object is "equal to" this one.
    final int
    Returns a hash code value for this object.
    Returns the value of the mayorPostfix record component.
    Returns the value of the mayorPrefix record component.
    Returns the value of the namePostfix record component.
    Returns the value of the namePrefix record component.
    double
    Returns the value of the peacefulCostMultiplier record component.
    double
    Returns the value of the resourceProductionModifier record component.
    final String
    Returns a string representation of this record class.
    int
    Returns the value of the townBlockBuyBonusLimit record component.
    int
    Returns the value of the townBlockLimit record component.
    Returns the value of the townBlockTypeLimits record component.
    int
    Returns the value of the townOutpostLimit record component.
    double
    Returns the value of the upkeepModifier record component.

    Methods inherited from class java.lang.Object

    clone, finalize, getClass, notify, notifyAll, wait, wait, wait
  • Constructor Details

    • TownLevel

      public TownLevel(String namePrefix, String namePostfix, String mayorPrefix, String mayorPostfix, int townBlockLimit, double upkeepModifier, double peacefulCostMultiplier, int townOutpostLimit, int townBlockBuyBonusLimit, double debtCapModifier, double resourceProductionModifier, double bankCapModifier, Map<String,Integer> townBlockTypeLimits)
      Creates an instance of a TownLevel record class.
      Parameters:
      namePrefix - the value for the namePrefix record component
      namePostfix - the value for the namePostfix record component
      mayorPrefix - the value for the mayorPrefix record component
      mayorPostfix - the value for the mayorPostfix record component
      townBlockLimit - the value for the townBlockLimit record component
      upkeepModifier - the value for the upkeepModifier record component
      peacefulCostMultiplier - the value for the peacefulCostMultiplier record component
      townOutpostLimit - the value for the townOutpostLimit record component
      townBlockBuyBonusLimit - the value for the townBlockBuyBonusLimit record component
      debtCapModifier - the value for the debtCapModifier record component
      resourceProductionModifier - the value for the resourceProductionModifier record component
      bankCapModifier - the value for the bankCapModifier record component
      townBlockTypeLimits - the value for the townBlockTypeLimits 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. 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.
    • namePrefix

      public String namePrefix()
      Returns the value of the namePrefix record component.
      Returns:
      the value of the namePrefix record component
    • namePostfix

      public String namePostfix()
      Returns the value of the namePostfix record component.
      Returns:
      the value of the namePostfix record component
    • mayorPrefix

      public String mayorPrefix()
      Returns the value of the mayorPrefix record component.
      Returns:
      the value of the mayorPrefix record component
    • mayorPostfix

      public String mayorPostfix()
      Returns the value of the mayorPostfix record component.
      Returns:
      the value of the mayorPostfix record component
    • townBlockLimit

      public int townBlockLimit()
      Returns the value of the townBlockLimit record component.
      Returns:
      the value of the townBlockLimit record component
    • upkeepModifier

      public double upkeepModifier()
      Returns the value of the upkeepModifier record component.
      Returns:
      the value of the upkeepModifier record component
    • peacefulCostMultiplier

      public double peacefulCostMultiplier()
      Returns the value of the peacefulCostMultiplier record component.
      Returns:
      the value of the peacefulCostMultiplier record component
    • townOutpostLimit

      public int townOutpostLimit()
      Returns the value of the townOutpostLimit record component.
      Returns:
      the value of the townOutpostLimit record component
    • townBlockBuyBonusLimit

      public int townBlockBuyBonusLimit()
      Returns the value of the townBlockBuyBonusLimit record component.
      Returns:
      the value of the townBlockBuyBonusLimit record component
    • debtCapModifier

      public double debtCapModifier()
      Returns the value of the debtCapModifier record component.
      Returns:
      the value of the debtCapModifier record component
    • resourceProductionModifier

      public double resourceProductionModifier()
      Returns the value of the resourceProductionModifier record component.
      Returns:
      the value of the resourceProductionModifier record component
    • bankCapModifier

      public double bankCapModifier()
      Returns the value of the bankCapModifier record component.
      Returns:
      the value of the bankCapModifier record component
    • townBlockTypeLimits

      public Map<String,Integer> townBlockTypeLimits()
      Returns the value of the townBlockTypeLimits record component.
      Returns:
      the value of the townBlockTypeLimits record component