Record Class DataTypeRegistry.Data
java.lang.Object
java.lang.Record
dev.latvian.mods.klib.data.DataTypeRegistry.Data
- Enclosing interface:
DataTypeRegistry
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionbyKey()Returns the value of thebyKeyrecord component.byType()Returns the value of thebyTyperecord component.Returns the value of thecommandInforecord component.final booleanIndicates whether some other object is "equal to" this one.final inthashCode()Returns a hash code value for this object.final StringtoString()Returns a string representation of this record class.
-
Constructor Details
-
Data
public Data(Map<net.minecraft.resources.ResourceKey<DataType<?>>, DataType<?>> byKey, Map<DataType<?>, net.minecraft.resources.ResourceKey<DataType<?>>> byType, Map<DataType<?>, DataTypeCommandInfo> commandInfo) Creates an instance of aDatarecord class.- Parameters:
byKey- the value for thebyKeyrecord componentbyType- the value for thebyTyperecord componentcommandInfo- the value for thecommandInforecord 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). -
byKey
-
byType
-
commandInfo
Returns the value of thecommandInforecord component.- Returns:
- the value of the
commandInforecord component
-