Package com.palmergames.bukkit.towny
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
ConstructorDescriptionTownLevel
(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 aTownLevel
record class. -
Method Summary
Modifier and TypeMethodDescriptiondouble
Returns the value of thebankCapModifier
record component.double
Returns the value of thedebtCapModifier
record component.final boolean
Indicates whether some other object is "equal to" this one.final int
hashCode()
Returns a hash code value for this object.Returns the value of themayorPostfix
record component.Returns the value of themayorPrefix
record component.Returns the value of thenamePostfix
record component.Returns the value of thenamePrefix
record component.double
Returns the value of thepeacefulCostMultiplier
record component.double
Returns the value of theresourceProductionModifier
record component.final String
toString()
Returns a string representation of this record class.int
Returns the value of thetownBlockBuyBonusLimit
record component.int
Returns the value of thetownBlockLimit
record component.Returns the value of thetownBlockTypeLimits
record component.int
Returns the value of thetownOutpostLimit
record component.double
Returns the value of theupkeepModifier
record component.
-
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 aTownLevel
record class.- Parameters:
namePrefix
- the value for thenamePrefix
record componentnamePostfix
- the value for thenamePostfix
record componentmayorPrefix
- the value for themayorPrefix
record componentmayorPostfix
- the value for themayorPostfix
record componenttownBlockLimit
- the value for thetownBlockLimit
record componentupkeepModifier
- the value for theupkeepModifier
record componentpeacefulCostMultiplier
- the value for thepeacefulCostMultiplier
record componenttownOutpostLimit
- the value for thetownOutpostLimit
record componenttownBlockBuyBonusLimit
- the value for thetownBlockBuyBonusLimit
record componentdebtCapModifier
- the value for thedebtCapModifier
record componentresourceProductionModifier
- the value for theresourceProductionModifier
record componentbankCapModifier
- the value for thebankCapModifier
record componenttownBlockTypeLimits
- the value for thetownBlockTypeLimits
record component
-
-
Method Details
-
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. -
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. -
equals
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 withObjects::equals(Object,Object)
; primitive components are compared with '=='. -
namePrefix
Returns the value of thenamePrefix
record component.- Returns:
- the value of the
namePrefix
record component
-
namePostfix
Returns the value of thenamePostfix
record component.- Returns:
- the value of the
namePostfix
record component
-
mayorPrefix
Returns the value of themayorPrefix
record component.- Returns:
- the value of the
mayorPrefix
record component
-
mayorPostfix
Returns the value of themayorPostfix
record component.- Returns:
- the value of the
mayorPostfix
record component
-
townBlockLimit
public int townBlockLimit()Returns the value of thetownBlockLimit
record component.- Returns:
- the value of the
townBlockLimit
record component
-
upkeepModifier
public double upkeepModifier()Returns the value of theupkeepModifier
record component.- Returns:
- the value of the
upkeepModifier
record component
-
peacefulCostMultiplier
public double peacefulCostMultiplier()Returns the value of thepeacefulCostMultiplier
record component.- Returns:
- the value of the
peacefulCostMultiplier
record component
-
townOutpostLimit
public int townOutpostLimit()Returns the value of thetownOutpostLimit
record component.- Returns:
- the value of the
townOutpostLimit
record component
-
townBlockBuyBonusLimit
public int townBlockBuyBonusLimit()Returns the value of thetownBlockBuyBonusLimit
record component.- Returns:
- the value of the
townBlockBuyBonusLimit
record component
-
debtCapModifier
public double debtCapModifier()Returns the value of thedebtCapModifier
record component.- Returns:
- the value of the
debtCapModifier
record component
-
resourceProductionModifier
public double resourceProductionModifier()Returns the value of theresourceProductionModifier
record component.- Returns:
- the value of the
resourceProductionModifier
record component
-
bankCapModifier
public double bankCapModifier()Returns the value of thebankCapModifier
record component.- Returns:
- the value of the
bankCapModifier
record component
-
townBlockTypeLimits
Returns the value of thetownBlockTypeLimits
record component.- Returns:
- the value of the
townBlockTypeLimits
record component
-