Liking cljdoc? Tell your friends :D

grasp


->cljmacro

(-> & forms)

->>cljmacro

(->> & forms)

emit-let-bindingsclj

(emit-let-bindings bindings)

form+value-sinkclj

(form+value-sink f v)

grabcljmacro

(grab exp)

It grabs the value of the expression parameter. It also grabs local bindings, stacktrace and the original form and adds to the metadata of the value if accepts metadata, so primitives like numbers for example won't have this feature.

This can introduce a memory leak depending on the sink you are using, for example if it is a atom, so keep this in mind and regularly purge it if you have a long running repl and is grabbing a lot of value.

It grabs the value of the expression parameter.
It also grabs local bindings, stacktrace and the original form
and adds to the metadata of the value if accepts metadata, so
primitives like numbers for example won't have this feature.

This can introduce a memory leak depending on the sink you are
using, for example if it is a atom, so keep this in mind and regularly
purge it if you have a long running repl and is grabbing a lot of value.
raw docstring

grab*clj

(grab* v original-form exception locals)

letcljmacro

(let bindings & body)

logclj


persistent-sink!clj

(persistent-sink! v)

It appends the value to the grasp/log atom. It is a sequence, so to get the last value you can just (last @grasp/log) and to reset the value you can (swap! grasp/log empty).

It appends the value to the grasp/log atom.
 It is a sequence, so to get the last value you can just
(last @grasp/log) and to reset the value you can
(swap! grasp/log empty).
raw docstring

pprint-sink!clj


rebl-sink!clj

(rebl-sink! v)

search-for-varclj

(search-for-var p)

If the parameter is a value it looks for the var that contains this value. For rich objects, like maps vectors and the like it is precise, but for primitives like numbers it will find the first var that contains that number, but maybe will not find the one you were actually looking for

If the parameter is a value it looks for the var
that contains this value. For rich objects, like maps
vectors and the like it is precise, but for primitives
like numbers it will find the first var that contains that
number, but maybe will not find the one you were actually
looking for
raw docstring

set-mapper!clj

(set-mapper! f)

Receives a fn that will be passed the grab metadata and the value itself and should return a new metadata for the grab. The only meta that will be added by this lib regardless is the attribute ':grasp/grasped?'. The mapper fn can be removed with the unset-mapper! fn.

Receives a fn that will be passed the grab metadata and the value
itself and should return a new metadata for the grab.
The only meta that will be added by this lib regardless is the attribute
':grasp/grasped?'.
The mapper fn can be removed with the `unset-mapper!` fn.
raw docstring

unset-mapper!clj

(unset-mapper!)

Remove any mapper added with set-mapper!

Remove any mapper added with `set-mapper!`
raw docstring

cljdoc is a website building & hosting documentation for Clojure/Script libraries

× close