FirstMatchFilter

A filter, which returns the first non-null evaluation from filters. It returns null, if none of filters return a non-null value, or filters is empty.

Parameters

TInput

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: IFilter<TInput, out TResult>)

Alternative constructor with variable arguments

constructor(filters: Collection<IFilter<TInput, out TResult>>)

Functions

Link copied to clipboard
open override fun evaluate(input: TInput): TResult?

Evaluates the filter with the given value.

Link copied to clipboard
open operator override fun iterator(): Iterator<IFilter<TInput, out TResult>>
Link copied to clipboard
open override fun toString(): String

Inherited functions

Link copied to clipboard
open fun dump(): String

Formats the current filter as a tree, and returns the formatted string.

Link copied to clipboard
open fun forEach(p0: Consumer<in IFilter<TInput, out TResult>>)
Link copied to clipboard