Record Class AtlasSpriteKubeIcon
java.lang.Object
java.lang.Record
dev.latvian.mods.kubejs.client.icon.AtlasSpriteKubeIcon
- All Implemented Interfaces:
KubeIcon
-
Field Summary
FieldsFields inherited from interface dev.latvian.mods.kubejs.client.icon.KubeIcon
CODEC, OPTIONAL_STREAM_CODEC, STREAM_CODEC -
Constructor Summary
ConstructorsConstructorDescriptionAtlasSpriteKubeIcon(Optional<net.minecraft.resources.ResourceLocation> atlas, net.minecraft.resources.ResourceLocation sprite) Creates an instance of aAtlasSpriteKubeIconrecord class. -
Method Summary
Modifier and TypeMethodDescriptionOptional<net.minecraft.resources.ResourceLocation> atlas()Returns the value of theatlasrecord component.final booleanIndicates whether some other object is "equal to" this one.KubeIconType<?> getType()final inthashCode()Returns a hash code value for this object.net.minecraft.resources.ResourceLocationsprite()Returns the value of thespriterecord component.final StringtoString()Returns a string representation of this record class.
-
Field Details
-
TYPE
-
-
Constructor Details
-
AtlasSpriteKubeIcon
public AtlasSpriteKubeIcon(Optional<net.minecraft.resources.ResourceLocation> atlas, net.minecraft.resources.ResourceLocation sprite) Creates an instance of aAtlasSpriteKubeIconrecord class.- Parameters:
atlas- the value for theatlasrecord componentsprite- the value for thespriterecord component
-
-
Method Details
-
getType
-
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). -
atlas
Returns the value of theatlasrecord component.- Returns:
- the value of the
atlasrecord component
-
sprite
public net.minecraft.resources.ResourceLocation sprite()Returns the value of thespriterecord component.- Returns:
- the value of the
spriterecord component
-