Liking cljdoc? Tell your friends :D

next.jdbc.protocols

This is the extensible core of the next generation java.jdbc library.

Sourceable -- for producing javax.sql.DataSource objects, Connectable -- for producing new java.sql.Connection objects, Executable -- for executing SQL operations, Preparable -- for producing new java.sql.PreparedStatement objects, Transactable -- for executing SQL operations transactionally.

This is the extensible core of the next generation java.jdbc library.

`Sourceable` -- for producing `javax.sql.DataSource` objects,
`Connectable` -- for producing new `java.sql.Connection` objects,
`Executable` -- for executing SQL operations,
`Preparable` -- for producing new `java.sql.PreparedStatement` objects,
`Transactable` -- for executing SQL operations transactionally.
raw docstring

Connectablecljprotocol

Protocol for producing a new JDBC connection that should be closed when you are finished with it.

Implementations are provided for DataSource, PreparedStatement, and Object, on the assumption that an Object can be turned into a DataSource.

Protocol for producing a new JDBC connection that should be closed when you
are finished with it.

Implementations are provided for `DataSource`, `PreparedStatement`, and
`Object`, on the assumption that an `Object` can be turned into a `DataSource`.

get-connectionclj

(get-connection this opts)

Produce a new java.sql.Connection for use with with-open.

Produce a new `java.sql.Connection` for use with `with-open`.
sourceraw docstring

Executablecljprotocol

Protocol for executing SQL operations.

Implementations are provided for Connection, DataSource, PreparedStatement, and Object, on the assumption that an Object can be turned into a DataSource and therefore used to get a Connection.

Protocol for executing SQL operations.

Implementations are provided for `Connection`, `DataSource`,
`PreparedStatement`, and `Object`, on the assumption that an `Object` can be
turned into a `DataSource` and therefore used to get a `Connection`.

-executeclj

(-execute this sql-params opts)

Produce a 'reducible' that, when reduced, executes the SQL and processes the rows of the ResultSet directly.

Produce a 'reducible' that, when reduced, executes the SQL and
processes the rows of the `ResultSet` directly.

-execute-allclj

(-execute-all this sql-params opts)

Executes the SQL and produces (by default) a vector of fully-realized, datafiable hash maps from the ResultSet.

Executes the SQL and produces (by default) a vector of
fully-realized, datafiable hash maps from the `ResultSet`.

-execute-oneclj

(-execute-one this sql-params opts)

Executes the SQL and produces the first row of the ResultSet as a fully-realized, datafiable hash map (by default).

Executes the SQL and produces the first row of the `ResultSet`
as a fully-realized, datafiable hash map (by default).
sourceraw docstring

Preparablecljprotocol

Protocol for producing a new java.sql.PreparedStatement that should be closed after use. Can be used by Executable functions.

Implementation is provided for Connection only.

Protocol for producing a new `java.sql.PreparedStatement` that should
be closed after use. Can be used by `Executable` functions.

Implementation is provided for `Connection` only.

prepareclj

(prepare this sql-params opts)

Produce a new java.sql.PreparedStatement for use with with-open.

Produce a new `java.sql.PreparedStatement` for use with `with-open`.
sourceraw docstring

Sourceablecljprotocol

Protocol for producing a javax.sql.DataSource.

Implementations are provided for strings, hash maps (db-spec structures), and also a DataSource (which just returns itself).

Extension via metadata is supported.

Protocol for producing a `javax.sql.DataSource`.

Implementations are provided for strings, hash maps (`db-spec` structures),
and also a `DataSource` (which just returns itself).

Extension via metadata is supported.

get-datasourceclj

(get-datasource this)

Produce a javax.sql.DataSource.

Produce a `javax.sql.DataSource`.
sourceraw docstring

Transactablecljprotocol

Protocol for running SQL operations in a transaction.

Implementations are provided for Connection, DataSource, and Object (on the assumption that an Object can be turned into a DataSource).

Protocol for running SQL operations in a transaction.

Implementations are provided for `Connection`, `DataSource`, and `Object`
(on the assumption that an `Object` can be turned into a `DataSource`).

-transactclj

(-transact this body-fn opts)

Run the body-fn inside a transaction.

Run the `body-fn` inside a transaction.
sourceraw docstring

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

× close