Package-level declarations
Types
Link copied to clipboard
Link copied to clipboard
Utility class to use connections given by the ConnectionSupplier.
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
@MissingServiceMessage(message = "Using a database required a service implementing ConnectionSupplier" )
Allows access to an SQL database.
Link copied to clipboard
Utility class to use connections given by the ConnectionSupplier, in a suspending style.
Link copied to clipboard
Sub-interface of ConnectionSupplier delegating simple HikariDataSource getters.
Link copied to clipboard
Functional interface for Java JDBC prepared statements.
Link copied to clipboard
Link copied to clipboard
class Transaction
Link copied to clipboard
Functional interface for Java JDBC transactions.
Functions
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
inline suspend fun <R> Database.preparedStatement(@Language(value = "PostgreSQL" ) sql: String, readOnly: Boolean = false, columnNames: Array<out String>, block: SuspendingPreparedStatement.() -> R): R
inline suspend fun <R> Database.preparedStatement(@Language(value = "PostgreSQL" ) sql: String, readOnly: Boolean = false, generatedKeys: Boolean = false, block: SuspendingPreparedStatement.() -> R): R
inline suspend fun <R> Database.preparedStatement(@Language(value = "PostgreSQL" ) sql: String, readOnly: Boolean = false, columnIndexes: IntArray, block: SuspendingPreparedStatement.() -> R): R
Creates a statement from the given SQL statement, runs the block, commits the changes and closes the connection.
Link copied to clipboard
inline suspend fun <R> Database.transactional(readOnly: Boolean = false, crossinline block: suspend Transaction.() -> R): R
Acquires a database connection, runs the block, commits the changes and closes the connection.
Link copied to clipboard
Sets the logger used to log the query.