API for clojure.java.jdbc - JDBC-based SQL Interface 0.3.5 (in development)

by Stephen C. Gilardi, Sean Corfield

Full namespace name: clojure.java.jdbc

Overview

A Clojure interface to SQL databases via JDBC

clojure.java.jdbc provides a simple abstraction for CRUD (create, read,
update, delete) operations on a SQL database, along with basic transaction
support. Basic DDL operations are also supported (create table, drop table,
access to table metadata).

Maps are used to represent records, making it easy to store and retrieve
data. Results can be processed using any standard sequence operations.

For most operations, Java's PreparedStatement is used so your SQL and
parameters can be represented as simple vectors where the first element
is the SQL string, with ? for each parameter, and the remaining elements
are the parameter values to be substituted. In general, operations return
the number of rows affected, except for a single record insert where any
generated keys are returned (as a map).

For more documentation, see:

http://clojure-doc.org/articles/ecosystem/java_jdbc/home.html

As of release 0.3.0, the API has undergone a major overhaul and most of the
original API has been deprecated in favor of a more idiomatic API. The
original API has been moved to java.jdbc.deprecated for backward
compatibility but it will be removed before a 1.0.0 release.

Protocols



IResultSetReadColumn

Protocol
Protocol for reading objects from the java.sql.ResultSet. Default
implementations (for Object and nil) return the argument, and the
Boolean implementation ensures a canonicalized true/false value,
but it can be extended to provide custom behavior for special types.
Known implementations: java.lang.Boolean, nil, Object

result-set-read-column

function
Usage: (result-set-read-column val rsmeta idx)
Function for transforming values after reading them from the database
Source


ISQLParameter

Protocol
Protocol for setting SQL parameters in statement objects, which
can convert from Clojure values. The default implementation just
delegates the conversion to ISQLValue's sql-value conversion and
uses .setObject on the parameter. It can be extended to use other
methods of PreparedStatement to convert and set parameter values.
Known implementations: nil, Object

set-parameter

function
Usage: (set-parameter val stmt ix)
Convert a Clojure value into a SQL value and store it as the ix'th
parameter in the given SQL statement object.
Source


ISQLValue

Protocol
Protocol for creating SQL values from Clojure values. Default
implementations (for Object and nil) just return the argument,
but it can be extended to provide custom behavior to support
exotic types supported by different databases.
Known implementations: nil, Object

sql-value

function
Usage: (sql-value val)
Convert a Clojure value into a SQL value.
Source

Public Variables and Functions



as-sql-name

function
Usage: (as-sql-name f)
       (as-sql-name f x)
Given a naming strategy function and a keyword or string, return
a string per that naming strategy.
A name of the form x.y is treated as multiple names, x, y, etc,
and each are turned into strings via the naming strategy and then
joined back together so x.y might become `x`.`y` if the naming
strategy quotes identifiers with `.
Source


create-table-ddl

function
Usage: (create-table-ddl table & specs)
Given a table name and column specs with an optional table-spec
return the DDL string for creating that table.
Source


db-connection

function
Usage: (db-connection db)
Returns the current database connection (or throws if there is none)
Source


db-do-commands

function
Usage: (db-do-commands db-spec sql-command & sql-commands)
       (db-do-commands db-spec transaction? sql-command & sql-commands)
Executes SQL commands on the specified database connection. Wraps the commands
in a transaction if transaction? is true. transaction? can be ommitted and it
defaults to true.
Source


db-do-prepared

function
Usage: (db-do-prepared db-spec sql & param-groups)
       (db-do-prepared db-spec transaction? sql & param-groups)
Executes an (optionally parameterized) SQL prepared statement on the
open database connection. Each param-group is a seq of values for all of
the parameters. transaction? can be omitted and defaults to true.
Return a seq of update counts (one count for each param-group).
Source


db-do-prepared-return-keys

function
Usage: (db-do-prepared-return-keys db sql param-group)
       (db-do-prepared-return-keys db transaction? sql param-group)
Executes an (optionally parameterized) SQL prepared statement on the
open database connection. The param-group is a seq of values for all of
the parameters. transaction? can be ommitted and will default to true.
Return the generated keys for the (single) update/insert.
Source


db-find-connection

function
Usage: (db-find-connection db)
Returns the current database connection (or nil if there is none)
Source


db-is-rollback-only

function
Usage: (db-is-rollback-only db)
Returns true if the outermost transaction will rollback rather than
commit when complete
Source


db-query-with-resultset

function
Usage: (db-query-with-resultset db-spec [sql-string & params] func)
       (db-query-with-resultset db-spec [stmt & params] func)
       (db-query-with-resultset db-spec [options-map sql-string & params] func)
Executes a query, then evaluates func passing in the raw ResultSet as an
 argument. The second argument is a vector containing either:
  [sql & params] - a SQL query, followed by any parameters it needs
  [stmt & params] - a PreparedStatement, followed by any parameters it needs
                    (the PreparedStatement already contains the SQL query)
  [options sql & params] - options and a SQL query for creating a
                    PreparedStatement, followed by any parameters it needs
See prepare-statement for supported options.
Source


db-set-rollback-only!

function
Usage: (db-set-rollback-only! db)
Marks the outermost transaction such that it will rollback rather than
commit when complete
Source


db-transaction

macro
Usage: (db-transaction binding & body)
Original name for with-db-transaction. Use that instead.
Deprecated since JDBC-based SQL Interface version 0.3.0
Source


db-transaction*

function
Usage: (db-transaction* db func & {:keys [isolation read-only?]})
Evaluates func as a transaction on the open database connection. Any
nested transactions are absorbed into the outermost transaction. By
default, all database updates are committed together as a group after
evaluating the outermost body, or rolled back on any uncaught
exception. If rollback is set within scope of the outermost transaction,
the entire transaction will be rolled back rather than committed when
complete.
The isolation option may be :none, :read-committed, :read-uncommitted,
:repeatable-read, or :serializable. Note that not all databases support
all of those isolation levels, and may either throw an exception or
substitute another isolation level.
The read-only? option puts the transaction in readonly mode (if supported).
Source


db-unset-rollback-only!

function
Usage: (db-unset-rollback-only! db)
Marks the outermost transaction such that it will not rollback when complete
Source


delete!

function
Usage: (delete! db table where-clause & {:keys [entities transaction?], :or {entities identity, transaction? true}})
Given a database connection, a table name and a where clause of columns to match,
perform a delete. The optional keyword arguments specify how to transform
column names in the map (default 'as-is') and whether to run the delete in
a transaction (default true).
Example:
  (delete! db :person ["zip = ?" 94546])
is equivalent to:
  (execute! db ["DELETE FROM person WHERE zip = ?" 94546])
Source


drop-table-ddl

function
Usage: (drop-table-ddl name & {:keys [entities], :or {entities identity}})
Given a table name, return the DDL string for dropping that table.
Source


execute!

function
Usage: (execute! db-spec [sql & params] :multi? false :transaction? true)
       (execute! db-spec [sql & param-groups] :multi? true :transaction? true)
Given a database connection and a vector containing SQL and optional parameters,
perform a general (non-select) SQL operation. The optional keyword argument specifies
whether to run the operation in a transaction or not (default true).
Source


get-connection

function
Usage: (get-connection {:keys [connection factory connection-uri classname subprotocol subname dbtype dbname host port datasource username password user name environment], :as db-spec})
Creates a connection to a database. db-spec is usually a map containing connection
parameters but can also be a URI or a String. The various possibilities are described
below:

Existing Connection:
  :connection  (required) an existing open connection that can be used
               but cannot be closed (only the parent connection can be closed)

Factory:
  :factory     (required) a function of one argument, a map of params
  (others)     (optional) passed to the factory function in a map

DriverManager:
  :subprotocol (required) a String, the jdbc subprotocol
  :subname     (required) a String, the jdbc subname
  :classname   (optional) a String, the jdbc driver class name
  (others)     (optional) passed to the driver as properties.

DriverManager (alternative):
  :dbtype      (required) a String, the type of the database (the jdbc subprotocol)
  :dbname      (required) a String, the name of the database
  :host        (optional) a String, the host name/IP of the database
                          (defaults to 127.0.0.1)
  :port        (optional) a Long, the port of the database
                          (defaults to 3306 for mysql, 1433 for mssql/jtds, else nil)
  (others)     (optional) passed to the driver as properties.

DataSource:
  :datasource  (required) a javax.sql.DataSource
  :username    (optional) a String
  :user        (optional) a String - an alternate alias for :username
                          (added after 0.3.0-beta2 for consistency JDBC-74)
  :password    (optional) a String, required if :username is supplied

JNDI:
  :name        (required) a String or javax.naming.Name
  :environment (optional) a java.util.Map

Raw:
  :connection-uri (required) a String
               Passed directly to DriverManager/getConnection

URI:
  Parsed JDBC connection string - see below

String:
  subprotocol://user:password@host:post/subname
               An optional prefix of jdbc: is allowed.
Source


insert!

function
Usage: (insert! db-spec table row-map :transaction? true :entities identity)
       (insert! db-spec table row-map & row-maps :transaction? true :entities identity)
       (insert! db-spec table col-name-vec col-val-vec & col-val-vecs :transaction? true :entities identity)
Given a database connection, a table name and either maps representing rows or
a list of column names followed by lists of column values, perform an insert.
Use :transaction? argument to specify whether to run in a transaction or not.
The default is true (use a transaction). Use :entities to specify how to convert
the table name and column names to SQL entities.
Source


metadata-result

function
Usage: (metadata-result rs-or-value & {:keys [identifiers as-arrays? row-fn result-set-fn], :or {identifiers lower-case, row-fn identity}})
If the argument is a java.sql.ResultSet, turn it into a result-set-seq,
else return it as-is. This makes working with metadata easier.
Also accepts :identifiers, :as-arrays?, :row-fn, and :result-set-fn
to control how the ResultSet is transformed and returned.
See query for more details.
Source


prepare-statement

function
Usage: (prepare-statement con sql & {:keys [return-keys result-type concurrency cursors fetch-size max-rows]})
Create a prepared statement from a connection, a SQL string and an
optional list of parameters:
  :return-keys true | false - default false
  :result-type :forward-only | :scroll-insensitive | :scroll-sensitive
  :concurrency :read-only | :updatable
  :cursors
  :fetch-size n
  :max-rows n
Source


print-sql-exception

function
Usage: (print-sql-exception exception)
Prints the contents of an SQLException to *out*
Source


print-sql-exception-chain

function
Usage: (print-sql-exception-chain exception)
Prints a chain of SQLExceptions to *out*
Source


print-update-counts

function
Usage: (print-update-counts exception)
Prints the update counts from a BatchUpdateException to *out*
Source


query

function
Usage: (query db-spec sql-and-params :as-arrays? false :identifiers lower-case :result-set-fn doall :row-fn identity)
       (query db-spec sql-and-params :as-arrays? true :identifiers lower-case :result-set-fn vec :row-fn identity)
       (query db-spec [sql-string & params])
       (query db-spec [stmt & params])
       (query db-spec [option-map sql-string & params])
Given a database connection and a vector containing SQL and optional parameters,
perform a simple database query. The optional keyword arguments specify how to
construct the result set:
  :result-set-fn - applied to the entire result set, default doall / vec
      if :as-arrays? true, :result-set-fn will default to vec
      if :as-arrays? false, :result-set-fn will default to doall
  :row-fn - applied to each row as the result set is constructed, default identity
  :identifiers - applied to each column name in the result set, default lower-case
  :as-arrays? - return the results as a set of arrays, default false.
The second argument is a vector containing a SQL string or PreparedStatement, followed
by any parameters it needs. See db-query-with-resultset for details.
Source


quoted

function
Usage: (quoted q)
       (quoted q x)
With a single argument, returns a naming strategy function that quotes
names. The single argument can either be a single character or a vector
pair of characters.
Can also be called with two arguments - a quoting argument and a name -
and returns the fully quoted string:
  (quoted \` "foo") will return "`foo`"
  (quoted [\[ \]] "foo") will return "[foo]"
Source


result-set-seq

function
Usage: (result-set-seq rs & {:keys [identifiers as-arrays?], :or {identifiers lower-case}})
Creates and returns a lazy sequence of maps corresponding to the rows in the
java.sql.ResultSet rs. Loosely based on clojure.core/resultset-seq but it
respects the specified naming strategy. Duplicate column names are made unique
by appending _N before applying the naming strategy (where N is a unique integer).
Source


update!

function
Usage: (update! db table set-map where-clause & {:keys [entities transaction?], :or {entities identity, transaction? true}})
Given a database connection, a table name, a map of column values to set and a
where clause of columns to match, perform an update. The optional keyword arguments
specify how column names (in the set / match maps) should be transformed (default
'as-is') and whether to run the update in a transaction (default true).
Example:
  (update! db :person {:zip 94540} ["zip = ?" 94546])
is equivalent to:
  (execute! db ["UPDATE person SET zip = ? WHERE zip = ?" 94540 94546])
Source


with-db-connection

macro
Usage: (with-db-connection binding & body)
Evaluates body in the context of an active connection to the database.
(with-db-connection [con-db db-spec]
  ... con-db ...)
Source


with-db-metadata

macro
Usage: (with-db-metadata binding & body)
Evaluates body in the context of an active connection with metadata bound
to the specified name. See also metadata-result for dealing with the results
of operations that retrieve information from the metadata.
(with-db-metadata [md db-spec]
  ... md ...)
Source


with-db-transaction

macro
Usage: (with-db-transaction binding & body)
Evaluates body in the context of a transaction on the specified database connection.
The binding provides the database connection for the transaction and the name to which
that is bound for evaluation of the body. The binding may also specify the isolation
level for the transaction, via the :isolation option and/or set the transaction to
readonly via the :read-only? option.
(with-db-transaction [t-con db-spec :isolation level :read-only? true]
  ... t-con ...)
See db-transaction* for more details.
Source

clojure.java.jdbc.deprecated

A Clojure interface to SQL databases via JDBC

This namespace contains the old API (0.2.3) which was deprecated in the 0.3.0
release and is provided for backward compatibility. This API will be removed
completely before a 1.0.0 release so will need to migrate code to the new API
before that release.

clojure.java.jdbc provides a simple abstraction for CRUD (create, read,
update, delete) operations on a SQL database, along with basic transaction
support. Basic DDL operations are also supported (create table, drop table,
access to table metadata).

Maps are used to represent records, making it easy to store and retrieve
data. Results can be processed using any standard sequence operations.

For most operations, Java's PreparedStatement is used so your SQL and
parameters can be represented as simple vectors where the first element
is the SQL string, with ? for each parameter, and the remaining elements
are the parameter values to be substituted. In general, operations return
the number of rows affected, except for a single record insert where any
generated keys are returned (as a map).

Public Variables and Functions



as-identifier

function
Usage: (as-identifier x)
       (as-identifier x f-entity)
Given a keyword, convert it to a string using the current naming
strategy.
Given a string, return it as-is.
Source


as-key

function
Usage: (as-key f x)
Given a naming strategy and a string, return the string as a
keyword per that naming strategy. Given (a naming strategy and)
a keyword, return it as-is.
Source


as-keyword

function
Usage: (as-keyword x)
       (as-keyword x f-keyword)
Given an entity name (string), convert it to a keyword using the
current naming strategy.
Given a keyword, return it as-is.
Source


as-named-identifier

function
Usage: (as-named-identifier naming-strategy x)
Given a naming strategy and a keyword, return the keyword as a string using the 
entity naming strategy.
Given a naming strategy and a string, return the string as-is.
The naming strategy should either be a function (the entity naming strategy) or 
a map containing :entity and/or :keyword keys which provide the entity naming
strategy and/or keyword naming strategy respectively.
Source


as-named-keyword

function
Usage: (as-named-keyword naming-strategy x)
Given a naming strategy and a string, return the string as a keyword using the 
keyword naming strategy.
Given a naming strategy and a keyword, return the keyword as-is.
The naming strategy should either be a function (the entity naming strategy) or 
a map containing :entity and/or :keyword keys which provide the entity naming
strategy and/or keyword naming strategy respectively.
Note that providing a single function will cause the default keyword naming
strategy to be used!
Source


as-quoted-identifier

function
Usage: (as-quoted-identifier q x)
Given a quote pattern - either a single character or a pair of characters in
a vector - and a keyword, return the keyword as a string using a simple
quoting naming strategy.
Given a qote pattern and a string, return the string as-is.
  (as-quoted-identifier X :name) will return XnameX as a string.
  (as-quoted-identifier [A B] :name) will return AnameB as a string.
Source


as-quoted-str

function
Usage: (as-quoted-str q x)
Given a quoting pattern - either a single character or a vector pair of
characters - and a string, return the quoted string:
  (as-quoted-str X foo) will return XfooX
  (as-quoted-str [A B] foo) will return AfooB
Source


as-str

function
Usage: (as-str f x)
Given a naming strategy and a keyword, return the keyword as a
string per that naming strategy. Given (a naming strategy and)
a string, return it as-is.
A keyword of the form :x.y is treated as keywords :x and :y,
both are turned into strings via the naming strategy and then
joined back together so :x.y might become `x`.`y` if the naming
strategy quotes identifiers with `.
Source


connection

function
Usage: (connection)
Returns the current database connection (or throws if there is none)
Source


create-table

function
Usage: (create-table name & specs)
Creates a table on the open database connection given a table name and
specs. Each spec is either a column spec: a vector containing a column
name and optionally a type and other constraints, or a table-level
constraint: a vector containing words that express the constraint. An
optional suffix to the CREATE TABLE DDL describing table attributes may
by provided as :table-spec {table-attributes-string}. All words used to
describe the table may be supplied as strings or keywords.
Source


create-table-ddl

function
Usage: (create-table-ddl name & specs)
Given a table name and column specs with an optional table-spec
return the DDL string for creating a table based on that.
Source


delete-rows

function
Usage: (delete-rows table where-params)
Deletes rows from a table. where-params is a vector containing a string
providing the (optionally parameterized) selection criteria followed by
values for any parameters.
Source


do-commands

function
Usage: (do-commands & commands)
Executes SQL commands on the open database connection.
Source


do-prepared

function
Usage: (do-prepared sql & param-groups)
Executes an (optionally parameterized) SQL prepared statement on the
open database connection. Each param-group is a seq of values for all of
the parameters.
Return a seq of update counts (one count for each param-group).
Source


do-prepared-return-keys

function
Usage: (do-prepared-return-keys sql param-group)
Executes an (optionally parameterized) SQL prepared statement on the
open database connection. The param-group is a seq of values for all of
the parameters.
Return the generated keys for the (single) update/insert.
Source


drop-table

function
Usage: (drop-table name)
Drops a table on the open database connection given its name, a string
or keyword
Source


find-connection

function
Usage: (find-connection)
Returns the current database connection (or nil if there is none)
Source


insert-record

function
Usage: (insert-record table record)
Inserts a single record into a table. A record is a map from strings or
keywords (identifying columns) to values.
Returns a map of the generated keys.
Source


insert-records

function
Usage: (insert-records table & records)
Inserts records into a table. records are maps from strings or keywords
(identifying columns) to values. Inserts the records one at a time.
Returns a sequence of maps containing the generated keys for each record.
Source


insert-rows

function
Usage: (insert-rows table & rows)
Inserts complete rows into a table. Each row is a vector of values for
each of the table's columns in order.
If a single row is inserted, returns a map of the generated keys.
Source


insert-values

function
Usage: (insert-values table column-names & value-groups)
Inserts rows into a table with values for specified columns only.
column-names is a vector of strings or keywords identifying columns. Each
value-group is a vector containing a values for each column in
order. When inserting complete rows (all columns), consider using
insert-rows instead.
If a single set of values is inserted, returns a map of the generated keys.
Source


is-rollback-only

function
Usage: (is-rollback-only)
Returns true if the outermost transaction will rollback rather than
commit when complete
Source


prepare-statement

function
Usage: (prepare-statement con sql & {:keys [return-keys result-type concurrency cursors fetch-size max-rows]})
Create a prepared statement from a connection, a SQL string and an
optional list of parameters:
  :return-keys true | false - default false
  :result-type :forward-only | :scroll-insensitive | :scroll-sensitive
  :concurrency :read-only | :updatable
  :fetch-size n
  :max-rows n
Source


print-sql-exception

function
Usage: (print-sql-exception exception)
Prints the contents of an SQLException to *out*
Source


print-sql-exception-chain

function
Usage: (print-sql-exception-chain exception)
Prints a chain of SQLExceptions to *out*
Source


print-update-counts

function
Usage: (print-update-counts exception)
Prints the update counts from a BatchUpdateException to *out*
Source


resultset-seq

function
Usage: (resultset-seq rs)
Creates and returns a lazy sequence of maps corresponding to
the rows in the java.sql.ResultSet rs. Based on clojure.core/resultset-seq
but it respects the current naming strategy. Duplicate column names are
made unique by appending _N before applying the naming strategy (where
N is a unique integer).
Source


set-rollback-only

function
Usage: (set-rollback-only)
Marks the outermost transaction such that it will rollback rather than
commit when complete
Source


transaction

macro
Usage: (transaction & body)
Evaluates body as a transaction on the open database connection. Any
nested transactions are absorbed into the outermost transaction. By
default, all database updates are committed together as a group after
evaluating the outermost body, or rolled back on any uncaught
exception. If set-rollback-only is called within scope of the outermost
transaction, the entire transaction will be rolled back rather than
committed when complete.
Source


transaction*

function
Usage: (transaction* func)
Evaluates func as a transaction on the open database connection. Any
nested transactions are absorbed into the outermost transaction. By
default, all database updates are committed together as a group after
evaluating the outermost body, or rolled back on any uncaught
exception. If rollback is set within scope of the outermost transaction,
the entire transaction will be rolled back rather than committed when
complete.
Source


update-or-insert-values

function
Usage: (update-or-insert-values table where-params record)
Updates values on selected rows in a table, or inserts a new row when no
existing row matches the selection criteria. where-params is a vector
containing a string providing the (optionally parameterized) selection
criteria followed by values for any parameters. record is a map from
strings or keywords (identifying columns) to updated values.
Source


update-values

function
Usage: (update-values table where-params record)
Updates values on selected rows in a table. where-params is a vector
containing a string providing the (optionally parameterized) selection
criteria followed by values for any parameters. record is a map from
strings or keywords (identifying columns) to updated values.
Source


with-connection

macro
Usage: (with-connection db-spec & body)
Evaluates body in the context of a new connection to a database then
closes the connection. db-spec is a map containing values for one of the
following parameter sets:

Factory:
  :factory     (required) a function of one argument, a map of params
  (others)     (optional) passed to the factory function in a map

DriverManager:
  :subprotocol (required) a String, the jdbc subprotocol
  :subname     (required) a String, the jdbc subname
  :classname   (optional) a String, the jdbc driver class name
  (others)     (optional) passed to the driver as properties.

DataSource:
  :datasource  (required) a javax.sql.DataSource
  :username    (optional) a String
  :password    (optional) a String, required if :username is supplied

JNDI:
  :name        (required) a String or javax.naming.Name
  :environment (optional) a java.util.Map

Raw:
  :connection-uri (required) a String
               Passed directly to DriverManager/getConnection

URI:
  Parsed JDBC connection string - see below

String:
  subprotocol://user:password@host:post/subname
               An optional prefix of jdbc: is allowed.
Source


with-connection*

function
Usage: (with-connection* db-spec func)
Evaluates func in the context of a new connection to a database then
closes the connection.
Source


with-naming-strategy

macro
Usage: (with-naming-strategy naming-strategy & body)
Evaluates body in the context of a naming strategy.
The naming strategy is either a function - the entity naming strategy - or
a map containing :entity and/or :keyword keys which provide the entity naming
strategy and/or the keyword naming strategy respectively. The default entity
naming strategy is identity; the default keyword naming strategy is lower-case.
Source


with-query-results

macro
Usage: (with-query-results results sql-params & body)
Executes a query, then evaluates body with results bound to a seq of the
results. sql-params is a vector containing either:
  [sql & params] - a SQL query, followed by any parameters it needs
  [stmt & params] - a PreparedStatement, followed by any parameters it needs
                    (the PreparedStatement already contains the SQL query)
  [options sql & params] - options and a SQL query for creating a
                    PreparedStatement, follwed by any parameters it needs
See prepare-statement for supported options.
Source


with-query-results*

function
Usage: (with-query-results* sql-params func)
Executes a query, then evaluates func passing in a seq of the results as
an argument. The first argument is a vector containing either:
  [sql & params] - a SQL query, followed by any parameters it needs
  [stmt & params] - a PreparedStatement, followed by any parameters it needs
                    (the PreparedStatement already contains the SQL query)
  [options sql & params] - options and a SQL query for creating a
                    PreparedStatement, follwed by any parameters it needs
See prepare-statement for supported options.
Source


with-quoted-identifiers

macro
Usage: (with-quoted-identifiers q & body)
Evaluates body in the context of a simple quoting naming strategy.
Source
Logo & site design by Tom Hickey.
Clojure auto-documentation system by Tom Faulhaber.