Class PaperBooleanInput
java.lang.Object
io.github.projectunified.unidialog.paper.input.PaperDialogInput
io.github.projectunified.unidialog.paper.input.PaperBooleanInput
- All Implemented Interfaces:
AdventureBooleanInput<PaperBooleanInput>
,AdventureSupport
,BooleanInput<PaperBooleanInput>
public class PaperBooleanInput
extends PaperDialogInput
implements AdventureBooleanInput<PaperBooleanInput>
-
Field Summary
Fields inherited from class io.github.projectunified.unidialog.paper.input.PaperDialogInput
key
-
Constructor Summary
ConstructorsConstructorDescriptionPaperBooleanInput
(String key, Function<String, net.kyori.adventure.text.Component> componentDeserializer) -
Method Summary
Modifier and TypeMethodDescriptionio.papermc.paper.registry.data.dialog.input.DialogInput
initial
(boolean initial) Set the initial value of the boolean input.label
(net.kyori.adventure.text.Component label) Set the label for the input.Set the text to be sent when the input is false.Set the text to be sent when the input is true.Methods inherited from class io.github.projectunified.unidialog.paper.input.PaperDialogInput
getComponentDeserializer
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface io.github.projectunified.unidialog.adventure.input.AdventureBooleanInput
label
Methods inherited from interface io.github.projectunified.unidialog.adventure.support.AdventureSupport
deserialize, getComponentDeserializer
-
Constructor Details
-
PaperBooleanInput
-
-
Method Details
-
label
Description copied from interface:AdventureBooleanInput
Set the label for the input.- Specified by:
label
in interfaceAdventureBooleanInput<PaperBooleanInput>
- Parameters:
label
- the label to display for the input- Returns:
- the current instance for method chaining
-
initial
Description copied from interface:BooleanInput
Set the initial value of the boolean input.- Specified by:
initial
in interfaceBooleanInput<PaperBooleanInput>
- Parameters:
initial
- the initial value (true or false)- Returns:
- the current instance for method chaining
-
onTrue
Description copied from interface:BooleanInput
Set the text to be sent when the input is true.- Specified by:
onTrue
in interfaceBooleanInput<PaperBooleanInput>
- Parameters:
onTrue
- the text to be sent when the input is true- Returns:
- the current instance for method chaining
-
onFalse
Description copied from interface:BooleanInput
Set the text to be sent when the input is false.- Specified by:
onFalse
in interfaceBooleanInput<PaperBooleanInput>
- Parameters:
onFalse
- the text to be sent when the input is false- Returns:
- the current instance for method chaining
-
getDialogInput
public io.papermc.paper.registry.data.dialog.input.DialogInput getDialogInput()- Specified by:
getDialogInput
in classPaperDialogInput
-