common/src/extension/function library
A collection of combinators and pure functions.
Functions
-
constant<
T, U> (T x) → T Function(U) - The Constant function.
-
curry2<
A, B, C> (C f(A, B)) → C Function(B) Function(A) - Binary function currying. Allows for partial application of binary functions.
-
identity<
T> (T x) → T - The Identity function.
-
isFalse(
bool x) → bool -
Tests whether the given boolean argument
x
is false. -
isNotNull<
T> (T? x) → bool -
Tests whether the given argument
x
is notnull
. -
isNull<
T> (T? x) → bool -
Tests whether the given argument
x
isnull
. -
not<
T> (bool p(T)) → bool Function(T) - Inverses a predicate boolean evaluation.
-
repeat(
int times, void body()) → void -
Repeatedly calls the given function
body
, the given amount oftimes
.