First Match Filter
public class FirstMatchFilter<TInput extends Object, TResult extends Object> implements IFilter<TInput, TResult>, Iterable<IFilter<TInput, ? extends TResult>>(source)
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
public FirstMatchFilter<TInput, TResult> FirstMatchFilter<TInput extends Any, TResult extends Any>(IFilter<TInput, ? extends TResult> filters)
Alternative constructor with variable arguments
public FirstMatchFilter<TInput, TResult> FirstMatchFilter<TInput extends Any, TResult extends Any>(Collection<IFilter<TInput, ? extends TResult>> filters)