Package net.minecraft.dialog.input
Record Class TextInputControl
java.lang.Object
java.lang.Record
net.minecraft.dialog.input.TextInputControl
- Record Components:
width
-label
-labelVisible
-initial
-maxLength
-multiline
-
- All Implemented Interfaces:
InputControl
public record TextInputControl(int width, Text label, boolean labelVisible, String initial, int maxLength, Optional<TextInputControl.Multiline> multiline)
extends Record
implements InputControl
- Mappings:
Namespace Name named net/minecraft/dialog/input/TextInputControl
intermediary net/minecraft/class_11444
official asu
named width
intermediary comp_4351
official c
named label
intermediary comp_4352
official d
named labelVisible
intermediary comp_4353
official e
named initial
intermediary comp_4354
official f
named maxLength
intermediary comp_4383
official g
named multiline
intermediary comp_4384
official h
-
Nested Class Summary
Nested Classes -
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final com.mojang.serialization.MapCodec
<TextInputControl> private final String
The field for theinitial
record component.private final Text
The field for thelabel
record component.private final boolean
The field for thelabelVisible
record component.private final int
The field for themaxLength
record component.private final Optional
<TextInputControl.Multiline> The field for themultiline
record component.private final int
The field for thewidth
record component. -
Constructor Summary
ConstructorsConstructorDescriptionTextInputControl
(int int2, Text text, boolean bool, String string, int int3, Optional<TextInputControl.Multiline> optional) -
Method Summary
Modifier and TypeMethodDescriptionfinal boolean
Indicates whether some other object is "equal to" this one.com.mojang.serialization.MapCodec
<TextInputControl> getCodec()
final int
hashCode()
Returns a hash code value for this object.initial()
Returns the value of theinitial
record component.label()
Returns the value of thelabel
record component.boolean
Returns the value of thelabelVisible
record component.int
Returns the value of themaxLength
record component.Returns the value of themultiline
record component.final String
toString()
Returns a string representation of this record class.int
width()
Returns the value of thewidth
record component.
-
Field Details
-
width
private final int widthThe field for thewidth
record component. -
label
The field for thelabel
record component. -
labelVisible
private final boolean labelVisibleThe field for thelabelVisible
record component. -
initial
The field for theinitial
record component. -
maxLength
private final int maxLengthThe field for themaxLength
record component. -
multiline
The field for themultiline
record component. -
CODEC
- Mappings:
Namespace Name Mixin selector named CODEC
Lnet/minecraft/dialog/input/TextInputControl;CODEC:Lcom/mojang/serialization/MapCodec;
intermediary field_60650
Lnet/minecraft/class_11444;field_60650:Lcom/mojang/serialization/MapCodec;
official a
Lasu;a:Lcom/mojang/serialization/MapCodec;
-
-
Constructor Details
-
TextInputControl
public TextInputControl(int int2, Text text, boolean bool, String string, int int3, Optional<TextInputControl.Multiline> optional)
-
-
Method Details
-
getCodec
- Specified by:
getCodec
in interfaceInputControl
- Mappings:
Namespace Name Mixin selector named getCodec
Lnet/minecraft/dialog/input/InputControl;getCodec()Lcom/mojang/serialization/MapCodec;
intermediary method_71717
Lnet/minecraft/class_11438;method_71717()Lcom/mojang/serialization/MapCodec;
official a
Lasq;a()Lcom/mojang/serialization/MapCodec;
-
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 '=='. -
width
public int width()Returns the value of thewidth
record component.- Returns:
- the value of the
width
record component
-
label
Returns the value of thelabel
record component.- Returns:
- the value of the
label
record component
-
labelVisible
public boolean labelVisible()Returns the value of thelabelVisible
record component.- Returns:
- the value of the
labelVisible
record component
-
initial
Returns the value of theinitial
record component.- Returns:
- the value of the
initial
record component
-
maxLength
public int maxLength()Returns the value of themaxLength
record component.- Returns:
- the value of the
maxLength
record component
-
multiline
Returns the value of themultiline
record component.- Returns:
- the value of the
multiline
record component
-