module Clear::Util
Overview
A set of method(s) useful for building Clear ORM.
Extended Modules
Defined in:
clear/util.crInstance Method Summary
-
#hash_union(h1 : Hash(A, B), h2 : Hash(C, D)) : Hash(A | C, B | D) forall A, B, C, D
Return a new hash which is union of two hash (some kind of deep merge)
-
#lambda(u : U.class, v : V.class, &block : U -> V) forall U, V
Equivalent to ruby's lambda with one parameter.
Instance Method Detail
def hash_union(h1 : Hash(A, B), h2 : Hash(C, D)) : Hash(A | C, B | D) forall A, B, C, D
#
Return a new hash which is union of two hash (some kind of deep merge)
Equivalent to ruby's lambda with one parameter. This method is useful combined with the macro system of Crystal.