Package net.minecraft.client.data.models
Record Class ItemModelGenerators.TrimMaterialData
java.lang.Object
java.lang.Record
net.minecraft.client.data.models.ItemModelGenerators.TrimMaterialData
- Enclosing class:
ItemModelGenerators
public static record ItemModelGenerators.TrimMaterialData(String name, ResourceKey<TrimMaterial> materialKey, Map<ResourceKey<EquipmentAsset>,String> overrideArmorMaterials)
extends Record
-
Field Summary
FieldsModifier and TypeFieldDescriptionprivate final ResourceKey<TrimMaterial> The field for thematerialKeyrecord component.private final StringThe field for thenamerecord component.private final Map<ResourceKey<EquipmentAsset>, String> The field for theoverrideArmorMaterialsrecord component. -
Constructor Summary
ConstructorsConstructorDescriptionTrimMaterialData(String name, ResourceKey<TrimMaterial> materialKey, Map<ResourceKey<EquipmentAsset>, String> overrideArmorMaterials) Creates an instance of aTrimMaterialDatarecord class. -
Method Summary
Modifier and TypeMethodDescriptionfinal booleanIndicates whether some other object is "equal to" this one.final inthashCode()Returns a hash code value for this object.Returns the value of thematerialKeyrecord component.name()Returns the value of thenamerecord component.Returns the value of theoverrideArmorMaterialsrecord component.textureName(ResourceKey<EquipmentAsset> pKey) final StringtoString()Returns a string representation of this record class.
-
Field Details
-
name
The field for thenamerecord component. -
materialKey
The field for thematerialKeyrecord component. -
overrideArmorMaterials
The field for theoverrideArmorMaterialsrecord component.
-
-
Constructor Details
-
TrimMaterialData
public TrimMaterialData(String name, ResourceKey<TrimMaterial> materialKey, Map<ResourceKey<EquipmentAsset>, String> overrideArmorMaterials) Creates an instance of aTrimMaterialDatarecord class.- Parameters:
name- the value for thenamerecord componentmaterialKey- the value for thematerialKeyrecord componentoverrideArmorMaterials- the value for theoverrideArmorMaterialsrecord component
-
-
Method Details
-
textureName
-
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 thenamerecord component.- Returns:
- the value of the
namerecord component
-
materialKey
Returns the value of thematerialKeyrecord component.- Returns:
- the value of the
materialKeyrecord component
-
overrideArmorMaterials
Returns the value of theoverrideArmorMaterialsrecord component.- Returns:
- the value of the
overrideArmorMaterialsrecord component
-