Package ovh.mythmc.banco.api.items
Record Class BancoItem
java.lang.Object
java.lang.Record
ovh.mythmc.banco.api.items.BancoItem
- Record Components:
name
- a case-sensitive material's name, for example GOLD_INGOTdisplayName
- this item's display namelore
- this item's lore textcustomModelData
- this item's custom model datavalue
- value of this item
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionReturns the value of thecustomModelData
record component.Returns the value of thedisplayName
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.lore()
Returns the value of thelore
record component.@NotNull String
name()
Returns the value of thename
record component.final String
toString()
Returns a string representation of this record class.@NotNull BigDecimal
value()
Returns the value of thevalue
record component.
-
Constructor Details
-
BancoItem
public BancoItem(@NotNull @NotNull String name, String displayName, List<String> lore, Integer customModelData, @NotNull @NotNull BigDecimal value) Creates an instance of aBancoItem
record class.- Parameters:
name
- the value for thename
record componentdisplayName
- the value for thedisplayName
record componentlore
- the value for thelore
record componentcustomModelData
- the value for thecustomModelData
record componentvalue
- the value for thevalue
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. All components in this record class are compared withObjects::equals(Object,Object)
. -
name
Returns the value of thename
record component.- Returns:
- the value of the
name
record component
-
displayName
Returns the value of thedisplayName
record component.- Returns:
- the value of the
displayName
record component
-
lore
Returns the value of thelore
record component.- Returns:
- the value of the
lore
record component
-
customModelData
Returns the value of thecustomModelData
record component.- Returns:
- the value of the
customModelData
record component
-
value
Returns the value of thevalue
record component.- Returns:
- the value of the
value
record component
-