setSingleChoiceOption

@NonNull
open fun setSingleChoiceOption(@Nullable label: @Nullable CharSequence, isChecked: Boolean, @Nullable listener: @Nullable CompoundButton.OnCheckedChangeListener): @NonNull AlertDialog.Builder

Configures a single choice option label and checkbox listener on the AlertDialog.

Return

this Builder object for method chaining

Parameters

label

text label to display next to the single choice checkbox

isChecked

initial checked state

listener

listener invoked when checkbox state changes

Throws

if setMessage was not called first