clikt / com.github.ajalt.clikt.parameters.options / pair

pair

fun <EachT : Any, ValueT> NullableOption<EachT, ValueT>.pair(): NullableOption<Pair<ValueT, ValueT>, ValueT>

Change to option to take two values, held in a Pair

This must be called after converting the value type, and before other transforms.

Example:

val opt: Pair<Int, Int>? by option().int().pair()