Liking cljdoc? Tell your friends :D

com.github.ivarref.hookd


install!clj

(install! f classes-and-methods)
source

install-post!clj

(install-post! f classes-and-methods)

Like install! but ensures that f is only called post invocation.

The following contextual data is will always be present in the map passed to f:

KeyValue
:idUniquely identifies the call. Same value for pre and post calls.
:argsThe vector of args
:startNanoseconds since some fixed but arbitrary origin time.
:post?true
:stopNanoseconds since some fixed but arbitrary origin time.
:spent-nsNumber of nanoseconds elapsed.
:spent-msNumber of milliseconds elapsed. Coerced to long.
:resultThe result of applying the value of :function to :args.
:errorAny exception caught during computation of the result.
:error?True if an exception was thrown.
:thisThe object this. Will be nil for static methods.
Like `install!` but ensures that `f` is only called **post** invocation.

The following contextual data is will **always** be present in the map passed
to `f`:

| Key         | Value                                                            |
| ----------- | ---------------------------------------------------------------- |
| `:id`       | Uniquely identifies the call. Same value for pre and post calls. |
| `:args`     | The vector of args                                               |
| `:start`    | Nanoseconds since some fixed but arbitrary origin time.          |
| `:post?`    | `true`                                                           |
| `:stop`     | Nanoseconds since some fixed but arbitrary origin time.          |
| `:spent-ns` | Number of nanoseconds elapsed.                                   |
| `:spent-ms` | Number of milliseconds elapsed. Coerced to long.                 |
| `:result`   | The result of applying the value of `:function` to `:args`.      |
| `:error`    | Any exception caught during computation of the result.           |
| `:error?`   | True if an exception was thrown.                                 |
| `:this`     | The object `this`. Will be nil for static methods.               |
sourceraw docstring

install-pre!clj

(install-pre! f classes-and-methods)

Like install! but ensures that f is only called pre invocation.

The following contextual data is will always be present in the map passed to f:

KeyValue
:idUniquely identifies the call. Same value for pre and post calls.
:argsThe vector of args
:startNanoseconds since some fixed but arbitrary origin time.
:pre?true
:thisThe object this. Will be nil for static methods.
Like `install!` but ensures that `f` is only called **pre** invocation.

The following contextual data is will **always** be present in the map passed
to `f`:

| Key         | Value                                                            |
| ----------- | ---------------------------------------------------------------- |
| `:id`       | Uniquely identifies the call. Same value for pre and post calls. |
| `:args`     | The vector of args                                               |
| `:start`    | Nanoseconds since some fixed but arbitrary origin time.          |
| `:pre?`     | `true`                                                           |
| `:this`     | The object `this`. Will be nil for static methods.               |
sourceraw docstring

produce-wiretap-ctx-mapclj

(produce-wiretap-ctx-map java-str-map)
source

uninstall!clj

(uninstall!)
(uninstall! className)
source

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

× close