Package fi.evolver.script
Record Class Dialog.DialogRadioSelect
java.lang.Object
java.lang.Record
fi.evolver.script.Dialog.DialogRadioSelect
- All Implemented Interfaces:
Dialog.DialogEntry
- Enclosing class:
Dialog
public static record Dialog.DialogRadioSelect(String label, List<String> options, int defaultSelectedIndex)
extends Record
implements Dialog.DialogEntry
-
Constructor Summary
ConstructorsConstructorDescriptionDialogRadioSelect(String label, List<String> options) DialogRadioSelect(String label, List<String> options, int defaultSelectedIndex) Creates an instance of aDialogRadioSelectrecord class. -
Method Summary
Modifier and TypeMethodDescriptionintReturns the value of thedefaultSelectedIndexrecord component.final booleanIndicates whether some other object is "equal to" this one.final inthashCode()Returns a hash code value for this object.label()Returns the value of thelabelrecord component.options()Returns the value of theoptionsrecord component.final StringtoString()Returns a string representation of this record class.
-
Constructor Details
-
DialogRadioSelect
Creates an instance of aDialogRadioSelectrecord class.- Parameters:
label- the value for thelabelrecord componentoptions- the value for theoptionsrecord componentdefaultSelectedIndex- the value for thedefaultSelectedIndexrecord component
-
DialogRadioSelect
-
-
Method Details
-
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 '=='. -
label
Returns the value of thelabelrecord component.- Specified by:
labelin interfaceDialog.DialogEntry- Returns:
- the value of the
labelrecord component
-
options
Returns the value of theoptionsrecord component.- Returns:
- the value of the
optionsrecord component
-
defaultSelectedIndex
public int defaultSelectedIndex()Returns the value of thedefaultSelectedIndexrecord component.- Returns:
- the value of the
defaultSelectedIndexrecord component
-