allValues

fun <ID : Any> Field<ID, Boolean>.allValues(reductionType: ReductionType = ExcludingSelf): Boolean

Returns true if all Boolean values in the field are true.

This overload assumes the identity predicate (i.e., it checks that all values are true). The local value is included in the check if reductionType is it.unibo.collektive.stdlib.util.IncludingSelf (the default is ExcludingSelf).

Return

true if all applicable values are true, false otherwise.

Parameters

reductionType

controls whether the local value is included in the check.


inline fun <T> Field<*, T>.allValues(reductionType: ReductionType = ExcludingSelf, crossinline predicate: Predicate<T>): Boolean

Returns true if all values in the field satisfy the given predicate.

The local value is included in the check if reductionType is it.unibo.collektive.stdlib.util.IncludingSelf (the default is ExcludingSelf).

Return

true if all applicable values satisfy the predicate, false otherwise.

Parameters

reductionType

controls whether the local value is included in the check.

predicate

the condition to test for each value.