View source

class thx.Functions3

import thx.Functions;

Available on all platforms

Helper class for functions that take 3 arguments

Class Fields

static inline function curry<A, B, C, D>(f:A -> B -> C -> D):A -> B -> C -> D

static function fn<T, T2, T3, T4>(fn:T -> T2 -> T3 -> T4, restArgs:Dynamic):Dynamic

Lambda expressions

static function memoize<T1, T2, T3, TOut>(callback:T1 -> T2 -> T3 -> TOut, ?resolver:T1 -> T2 -> T3 -> String):T1 -> T2 -> T3 -> TOut

memoize wraps callback and calls it only once storing the result for future needs.

Computed results are stored in an internal map. The keys to this map are generated by the resolver function that by default directly converts the arguments into a string.

static inline function negate<T1, T2, T3>(callback:T1 -> T2 -> T3 -> Bool):T1 -> T2 -> T3 -> Bool

Wraps callback in a function that negates its results.

Toggle inherited fields