Record Class NameSignInfo.Entry
java.lang.Object
java.lang.Record
purplecreate.tramways.content.stationDeco.nameSign.info.NameSignInfo.Entry
- Enclosing class:
- NameSignInfo
public static record NameSignInfo.Entry(net.minecraft.world.entity.Display.TextDisplay.Align align, int offset, net.minecraft.world.item.DyeColor color)
extends Record
-
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final com.mojang.serialization.Codec<NameSignInfo.Entry>
static final NameSignInfo.Entry
-
Constructor Summary
ConstructorsConstructorDescriptionEntry
(net.minecraft.world.entity.Display.TextDisplay.Align align, int offset, net.minecraft.world.item.DyeColor color) Creates an instance of aEntry
record class. -
Method Summary
Modifier and TypeMethodDescriptionnet.minecraft.world.entity.Display.TextDisplay.Align
align()
Returns the value of thealign
record component.net.minecraft.world.item.DyeColor
color()
Returns the value of thecolor
record component.final boolean
Indicates whether some other object is "equal to" this one.forceCenteredIf
(boolean value) final int
hashCode()
Returns a hash code value for this object.int
offset()
Returns the value of theoffset
record component.final String
toString()
Returns a string representation of this record class.
-
Field Details
-
DEFAULT
-
CODEC
-
-
Constructor Details
-
Entry
public Entry(net.minecraft.world.entity.Display.TextDisplay.Align align, int offset, net.minecraft.world.item.DyeColor color) Creates an instance of aEntry
record class.- Parameters:
align
- the value for thealign
record componentoffset
- the value for theoffset
record componentcolor
- the value for thecolor
record component
-
-
Method Details
-
forceCentered
-
forceCenteredIf
-
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. Reference components are compared withObjects::equals(Object,Object)
; primitive components are compared with '=='. -
align
public net.minecraft.world.entity.Display.TextDisplay.Align align()Returns the value of thealign
record component.- Returns:
- the value of the
align
record component
-
offset
public int offset()Returns the value of theoffset
record component.- Returns:
- the value of the
offset
record component
-
color
public net.minecraft.world.item.DyeColor color()Returns the value of thecolor
record component.- Returns:
- the value of the
color
record component
-