clikt / com.github.ajalt.clikt.parameters.groups / required

required

fun OptionGroup> ChoiceGroup.required(): ChoiceGroup

If a groupChoice option is not called on the command line, throw a MissingParameter exception.

Example:

``` kotlin option().choice(“foo” to FooOptionGroup(), “bar” to BarOptionGroup()).required()

fun Any> MutuallyExclusiveOptions.required(): MutuallyExclusiveOptions

Make a mutuallyExclusiveOptions group required. If none of the options in the group are given, a UsageError is thrown.