Record Class DialogInput.NumberRange
java.lang.Object
java.lang.Record
net.minestom.server.dialog.DialogInput.NumberRange
- All Implemented Interfaces:
DialogInput
- Enclosing interface:
DialogInput
-
Nested Class Summary
Nested classes/interfaces inherited from interface DialogInput
DialogInput.Boolean, DialogInput.NumberRange, DialogInput.SingleOption, DialogInput.Text -
Field Summary
FieldsFields inherited from interface DialogInput
DEFAULT_WIDTH, REGISTRY -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionStructCodec<? extends DialogInput> codec()floatend()Returns the value of theendrecord component.final booleanIndicates whether some other object is "equal to" this one.final inthashCode()Returns a hash code value for this object.initial()Returns the value of theinitialrecord component.key()Returns the value of thekeyrecord component.label()Returns the value of thelabelrecord component.Returns the value of thelabelFormatrecord component.floatstart()Returns the value of thestartrecord component.step()Returns the value of thesteprecord component.final StringtoString()Returns a string representation of this record class.intwidth()Returns the value of thewidthrecord component.
-
Field Details
-
CODEC
-
-
Constructor Details
-
NumberRange
public NumberRange(String key, int width, Component label, String labelFormat, float start, float end, @Nullable @Nullable Float initial, @Nullable @Nullable Float step) Creates an instance of aNumberRangerecord class.- Parameters:
key- the value for thekeyrecord componentwidth- the value for thewidthrecord componentlabel- the value for thelabelrecord componentlabelFormat- the value for thelabelFormatrecord componentstart- the value for thestartrecord componentend- the value for theendrecord componentinitial- the value for theinitialrecord componentstep- the value for thesteprecord component
-
-
Method Details
-
codec
- Specified by:
codecin interfaceDialogInput
-
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. Reference components are compared withObjects::equals(Object,Object); primitive components are compared with thecomparemethod from their corresponding wrapper classes. -
key
Returns the value of thekeyrecord component.- Returns:
- the value of the
keyrecord component
-
width
public int width()Returns the value of thewidthrecord component.- Returns:
- the value of the
widthrecord component
-
label
Returns the value of thelabelrecord component.- Returns:
- the value of the
labelrecord component
-
labelFormat
Returns the value of thelabelFormatrecord component.- Returns:
- the value of the
labelFormatrecord component
-
start
public float start()Returns the value of thestartrecord component.- Returns:
- the value of the
startrecord component
-
end
public float end()Returns the value of theendrecord component.- Returns:
- the value of the
endrecord component
-
initial
-
step
-