Module Make.Map

val assoc_model : ?⁠comparator:('k'cmp) Core_kernel.Map.comparator -> ('input'model'result) t -> ('input('k'model'cmp) Core_kernel.Map.t('k'result'cmp) Core_kernel.Map.t) t

Transforms a component into a new component whose model and result are maps.

val associ_model : ?⁠comparator:('k'cmp) Core_kernel.Map.comparator -> ('k * 'input'model'result) t -> ('input('k'model'cmp) Core_kernel.Map.t('k'result'cmp) Core_kernel.Map.t) t

Transforms a component into a new component whose model and result are maps. The input for the transformed component also receives its key as an input.

val assoc_input : ?⁠comparator:('k'cmp) Core_kernel.Map.comparator -> ('input'model'result) t -> (('k'input'cmp) Core_kernel.Map.t'model('k'result'cmp) Core_kernel.Map.t) t

Transforms a component into a new component whose input and result are maps.

val associ_input : ?⁠comparator:('k'cmp) Core_kernel.Map.comparator -> ('k * 'input'model'result) t -> (('k'input'cmp) Core_kernel.Map.t'model('k'result'cmp) Core_kernel.Map.t) t

Transforms a component into a new component whose input and result are maps. The input for the transformed component also receives its key as an input.

val merge : ('input'model('k'r1'cmp) Base.Map.t) t -> ('input'model('k'r2'cmp) Base.Map.t) t -> f:(key:'k -> [ `Both of 'r1 * 'r2 | `Left of 'r1 | `Right of 'r2 ] -> 'result option) -> ('input'model('k'result'cmp) Base.Map.t) t

Given two components that produce maps, create a new component that produces a map that is merged according provided function f.