Package-level declarations

Types

Link copied to clipboard
class EnumChoiceConverter<E : Enum<E>, ChoiceEnum>(typeName: Key, getter: suspend (String, Locale) -> E?, choices: Map<Key, E>, var validator: Validator<E> = null) : ChoiceConverter<E>

Choice converter for enum arguments. Supports mapping up to 25 choices to an enum type.

Link copied to clipboard
class NumberChoiceConverter(radix: Int = DEFAULT_RADIX, choices: Map<Key, Long>, var validator: Validator<Long> = null) : ChoiceConverter<Long>

Choice converter for integer arguments. Supports mapping up to 25 choices to integers.

Link copied to clipboard
class StringChoiceConverter(choices: Map<Key, String>, var validator: Validator<String> = null) : ChoiceConverter<String>

Choice converter for string arguments. Supports mapping up to 25 choices to string.

Functions

Link copied to clipboard
inline fun <E : Enum<E>, ChoiceEnum> getEnum(arg: String, locale: Locale): E?

The default choice enum value getter — matches choice enums via a case-insensitive string comparison with the names.