allOptionsIf library

Functions

allOptionsIf<TOptionType, TOutput>(TOptionType selectedOption, Map<TOptionType, TOutput Function()> branches, [Map<List<TOptionType>, TOutput Function()>? branchesSameResult, TOutput? defaultValue = null]) → TOutput
case2<TOptionType, TValue>(TOptionType selectedOption, Map<TOptionType, TValue> branches, [TValue? defaultValue = null]) → TValue?
caseByType<TOptionType, TValue>(TOptionType selectedOption, Map<Type, TValue> branches, [TValue? defaultValue = null]) → TValue?
Limitation, Map<Type, TValue> - Type can be any type!