groupChoice

fun <T : OptionGroup> RawOption.groupChoice(choices: Map<String, T>): ChoiceGroup<T, T?>

Convert the option to an option group based on a fixed set of values.

Example:

option().groupChoice(mapOf("foo" to FooOptionGroup(), "bar" to BarOptionGroup()))

See also

fun <T : OptionGroup> RawOption.groupChoice(vararg choices: Pair<String, T>): ChoiceGroup<T, T?>

Convert the option to an option group based on a fixed set of values.

Example:

option().groupChoice("foo" to FooOptionGroup(), "bar" to BarOptionGroup())

See also