(combine-with-threader threader before-primary-afters)(combine-with-threader threader primary-methods {:keys [before after around]})Combine primary and auxiliary methods using a threading invoker, i.e. something you'd get by calling
threading-invoker. The way these methods are combined/reduced is the same, regarless of how args are threaded;
thus, various strategies such as :thread-first and :thread-last can both share the same reducer-fn.
Combine primary and auxiliary methods using a threading invoker, i.e. something you'd get by calling `threading-invoker`. The way these methods are combined/reduced is the same, regarless of how args are threaded; thus, various strategies such as `:thread-first` and `:thread-last` can both share the same `reducer-fn`.
(reducer-fn before-primary-after-methods)Reduces a series of before/combined-primary/after methods, threading the resulting values to the next method by
calling the invoke function, which is generated by threaded-invoker.
Reduces a series of before/combined-primary/after methods, threading the resulting values to the next method by calling the `invoke` function, which is generated by `threaded-invoker`.
(threading-invoker threading-type)Define a new 'threading invoker', which define how before/combined-primary/after methods should thread values to
subsequent methods. These methods take the initial values used to invoke a multifn, then return a pair like
[initial-value threading-fn]. The threading function is used to invoke any subsequent methods using only q single
value, the result of the previous method; if effectively partially binds subsequent methods so that they are always
invoked with the initial values of this invocation, excluding the threaded value.
Define a new 'threading invoker', which define how before/combined-primary/after methods should thread values to subsequent methods. These methods take the initial values used to invoke a multifn, then return a pair like `[initial-value threading-fn]`. The threading function is used to invoke any subsequent methods using only q single value, the result of the previous method; if effectively partially binds subsequent methods so that they are always invoked with the initial values of this invocation, excluding the threaded value.
(threading-method-combination threading-type)Create a new ThreadingMethodCombination using the keyword threading-type strategy, e.g. :thread-first or
:thread-last.
Create a new `ThreadingMethodCombination` using the keyword `threading-type` strategy, e.g. `:thread-first` or `:thread-last`.
cljdoc builds & hosts documentation for Clojure/Script libraries
| Ctrl+k | Jump to recent docs |
| ← | Move to previous article |
| → | Move to next article |
| Ctrl+/ | Jump to the search field |