Static methods

staticapplication<A, I, O> (fn:A ‑> Tuple2<I ‑> O, I>):A ‑> O

Returns a function that applies a function on the lhs of a tuple to the value on the rhs.

staticapply<I, O> (fn:I ‑> O, v:I):O

staticboth<A, B> (fn:A ‑> B):Tuple2<A, A> ‑> Tuple2<B, B>

Creates a function applying the same function to both the left and right portions of a Tuple2;

staticcompose<U, V, W> (f1:V ‑> W, f2:U ‑> V):U ‑> W

Returns a function that calls f1 with the output of f2.

staticfan<I, O> (a:I ‑> O):I ‑> Tuple2<O, O>

Returns a function that produces a Tuple2 from a value.

staticfirst<A, B, C, D> (fn1:A ‑> C):Tuple2<A, B> ‑> Tuple2<C, B>

Returns a function that applies fn1 to the left hand side of a Tuple

staticfromOption<A, B> (fn:A ‑> Option<B>):Option<A> ‑> Option<B>

staticfromR<A, B, C> (fn:B ‑> Either<A, C>):Either<A, B> ‑> Either<A, C>

staticleft<A, B, C> (fn:A ‑> C):Either<A, B> ‑> Either<C, B>

Returns a function that applies a function to the Left value of an Either.

staticmaybe<A, B> (fn:A ‑> B):Option<A> ‑> Option<B>

Produces a function that is only called in the event of Some(v) being passed to it.

staticpair<A, B, C, D> (fn1:A ‑> C, fn2:B ‑> D):Tuple2<A, B> ‑> Tuple2<C, D>

staticpinch<A, B, C> (fn0:Tuple2<A, A> ‑> Tuple2<B, C>):A ‑> Tuple2<B, C>

Creates a function that splits an input to it's inputs.

staticpure<A, B> (v:B):A ‑> B

Returns a function that produces v.

staticrepeat<I, O> (fn:I ‑> Either<I, O>):I ‑> O

staticright<A, B, D> (fn:B ‑> D):Either<A, B> ‑> Either<A, D>

Returns a function that applies a function to the Right value of an Either.

staticsecond<A, B, C, D> (fn1:B ‑> D):Tuple2<A, B> ‑> Tuple2<A, D>

Returns a function that applies fn1 to the right hand side of a Tuple

staticsplit<A, B, C> (split_:A ‑> B, _split:A ‑> C):A ‑> Tuple2<B, C>

Combines functions such that a single input is passed to both.

staticthen<A, B, C> (fn1:A ‑> B, fn2:B ‑> C):A ‑> C

Returns a function that applies fn1 then fn2 on the input

statictie<A, B, C> (bindl:A ‑> C, bindr:Tuple2<A, C> ‑> B):A ‑> B

Applies a function to the input, passing it's original input plus output forward to bindr.

staticunit<A, B> ():A ‑> A

Unit function. [[1,2],[3,4]].flatMap( Compose.unit() );//[1,2,3,4]