FirstMatchFilter

class FirstMatchFilter<T, TResult : Any>(filters: Iterable<<Error class: unknown class><T, out TResult>>) : Iterable<<Error class: unknown class><T, out TResult>> (source)

A filter, which returns the first IFilter.Result.Match result from filters. Only skips if all sub-filters skip, and only yields mismatch if no sub-filters yield match.

Parameters

T

The type the filter accepts

TResult

The type the filter returns

filters

The sub-filters to evaluate

Constructors

Link copied to clipboard
constructor(vararg filters: <Error class: unknown class><T, out TResult>)

Alternative constructor with variable arguments

constructor(filters: Iterable<<Error class: unknown class><T, out TResult>>)

Functions

Link copied to clipboard
open fun evaluate(value: T): <Error class: unknown class><out TResult>
Link copied to clipboard
open operator override fun iterator(): Iterator<<Error class: unknown class><T, out TResult>>
Link copied to clipboard
open override fun toString(): String

Inherited functions

Link copied to clipboard
open fun forEach(p0: Consumer<in <Error class: unknown class><T, out TResult>>)
Link copied to clipboard
open fun spliterator(): Spliterator<<Error class: unknown class><T, out TResult>>