Record Class ModRecord
java.lang.Object
java.lang.Record
net.neoforged.neoforge.server.jsonrpc.ModRecord
-
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final com.mojang.serialization.Codec<ModRecord> private final StringThe field for thedescriptionrecord component.private final StringThe field for thedisplayNamerecord component.private final StringThe field for themodIdrecord component.private final StringThe field for theversionrecord component. -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionReturns the value of thedescriptionrecord component.Returns the value of thedisplayNamerecord component.final booleanIndicates whether some other object is "equal to" this one.final inthashCode()Returns a hash code value for this object.modId()Returns the value of themodIdrecord component.final StringtoString()Returns a string representation of this record class.version()Returns the value of theversionrecord component.
-
Field Details
-
modId
The field for themodIdrecord component. -
version
The field for theversionrecord component. -
displayName
The field for thedisplayNamerecord component. -
description
The field for thedescriptionrecord component. -
CODEC
-
-
Constructor Details
-
ModRecord
-
ModRecord
Creates an instance of aModRecordrecord class.- Parameters:
modId- the value for themodIdrecord componentversion- the value for theversionrecord componentdisplayName- the value for thedisplayNamerecord componentdescription- the value for thedescriptionrecord component
-
-
Method Details
-
toString
-
hashCode
-
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). -
modId
Returns the value of themodIdrecord component.- Returns:
- the value of the
modIdrecord component
-
version
Returns the value of theversionrecord component.- Returns:
- the value of the
versionrecord component
-
displayName
Returns the value of thedisplayNamerecord component.- Returns:
- the value of the
displayNamerecord component
-
description
Returns the value of thedescriptionrecord component.- Returns:
- the value of the
descriptionrecord component
-