clj-libssh2.logging

Functions for weaving some detailed debug logging into every function in
clj-libssh2.

byte-array-type

init

(init)
Initialise the logging of clj-libssh2 by applying trace-ns to all of the
namespaces in the library if debug logging is enabled.

summarize-structure

multimethod

Given an object, trim down the larger items so that logging them doesn't
result in a combination of extreme performance degradataion and lack of
readability.

Arguments:

object The object to summarize.

Return:

An object of the same type and shape as the input, but with the larger parts
of the object summarized into a brief description of their contents.

trace-fn

(trace-fn fn-var level)
Hook a function so that all calls to it (and the results of those calls) are
logged at a given level.

Arguments:

fn-var A var pointing to the function to trace.
level  The log level at which the function call and result should be logged.

Return:

See robert.hooke/add-hook for the description of the return value.

trace-ns

(trace-ns ns-sym level)
Apply (trace-fn % level) to all functions in a given namespace.

Arguments:

ns-sym The symbolic name of a namespace.
level  The level to log all calls at.

Return:

nil