(coll-node? node)
Inputs: [node :- tsk/KeyMap] Returns: s/Bool
Inputs: [node :- tsk/KeyMap] Returns: s/Bool
(entry-node? node)
Inputs: [node :- tsk/KeyMap] Returns: s/Bool
Inputs: [node :- tsk/KeyMap] Returns: s/Bool
(non-nil-entries-fn coll)
Inputs: [coll :- (s/maybe tsk/KeyMap)]
Inputs: [coll :- (s/maybe tsk/KeyMap)]
(splatter data)
Inputs: [data]
Given arbitrary EDN data, returns a splat
that wraps and annotates each level for
collections (map/list/set), collection entries (map entries/list elements/set elements),
and primitive values (numbers/strings/keywords/symbols/nil/etc).
Inputs: [data] Given arbitrary EDN data, returns a `splat` that wraps and annotates each level for collections (map/list/set), collection entries (map entries/list elements/set elements), and primitive values (numbers/strings/keywords/symbols/nil/etc).
(splatter-walk intc data)
Inputs: [intc :- tsk/KeyMap data :- s/Any] Returns: s/Any
Convenience function for performing a stack-walk
using splattered data:
(it-> <data>
(splatter it)
(stack-walk <interceptor> it)
(unsplatter it))
Inputs: [intc :- tsk/KeyMap data :- s/Any] Returns: s/Any Convenience function for performing a `stack-walk` using splattered data: (it-> <data> (splatter it) (stack-walk <interceptor> it) (unsplatter it))
(splatter-walk-noop intc data)
Inputs: [intc :- tsk/KeyMap data :- s/Any] Returns: s/Any
Same as splatter-walk
but discards the result of each interceptor :enter
and :leave
function.
Inputs: [intc :- tsk/KeyMap data :- s/Any] Returns: s/Any Same as `splatter-walk` but discards the result of each interceptor `:enter` and `:leave` function.
(splatter-walk-spy data)
Inputs: [data :- s/Any] Returns: s/Any
LIke splatter-walk, but prints both node-history stack and subtree at each step.
Inputs: [data :- s/Any] Returns: s/Any LIke splatter-walk, but prints both node-history stack and subtree at each step.
(stack-identity stack node)
Inputs: [stack node]
An identity function for use with stack-walk
. It ignores the stack and returns the supplied node value.
Inputs: [stack node] An identity function for use with `stack-walk`. It ignores the stack and returns the supplied node value.
(stack-walk interceptor splatter)
Inputs: [interceptor :- tsk/KeyMap splatter :- tsk/KeyMap] Returns: s/Any
Uses an interceptor (with :enter
and :leave
functions) to walk a Splatter data structure. Each interceptor
function call receives a node-history stack as the first argument (current node => index 0)
Inputs: [interceptor :- tsk/KeyMap splatter :- tsk/KeyMap] Returns: s/Any Uses an interceptor (with `:enter` and `:leave` functions) to walk a Splatter data structure. Each interceptor function call receives a node-history stack as the first argument (current node => index 0)
(unsplatter splat)
Inputs: [splat :- tsk/KeyMap] Returns: s/Any
Remove annotations from a splat
, eliding any nil
values. Since the splatter
annotation never includes raw nil
values, any nil
detected by unsplatter
indicates a node or subtree has been deleted during prior processing
(eg via stack-walk
or splatter-walk
).
Inputs: [splat :- tsk/KeyMap] Returns: s/Any Remove annotations from a `splat`, eliding any `nil` values. Since the `splatter` annotation never includes raw `nil` values, any `nil` detected by `unsplatter` indicates a node or subtree has been deleted during prior processing (eg via `stack-walk` or `splatter-walk`).
cljdoc is a website building & hosting documentation for Clojure/Script libraries
× close