ValidationResult<T, E extends ValidationError> extension

Extensions to facilitate manipulating validation results.

on

Properties

firstError → E?
Gets the first error according to the composition sequence used creating of calling validation result
no setter

Methods

errorsGroupedBy<K>(Selector<E, K> tagSelector) Map<K, List<E>>
Returns a map of grouped validation errors keyed by a formfield type.
singleErrorsBy<K>(Selector<E, K> tagSelector) Map<K, String>
Returns a map of formfield, error key value pairs.