Package-level declarations

Types

Link copied to clipboard
sealed interface Result

Proof that one of ResultScope's methods was called. Functions that receive a ResultScope return this type to force exactly one result to be set before returning.

Link copied to clipboard
interface ResultScope

Scope used in places where SQLite expects a result value to be returned. Every method returns Result as proof that a result was set.

Functions

Link copied to clipboard

Sets the result to value, using SQLite's own convention for booleans, 1 for true and 0 for false, since SQLite has no dedicated boolean storage class.

Convenience overload of resultBoolean that returns null when value is null.

Link copied to clipboard
fun ResultScope.resultBuffer(value: Buffer?, size: Long = value?.byteSize ?: 0L, cleanup: (Buffer) -> Unit? = null): Result

Convenience overload of resultBuffer that returns null when value is null.

Link copied to clipboard

Convenience overload of resultByteArray that returns null when value is null.

Link copied to clipboard

Convenience overload of resultDouble that returns null when value is null.

Link copied to clipboard

Convenience overload of resultInt that returns null when value is null.

Link copied to clipboard

Convenience overload of resultLong that returns null when value is null.

Link copied to clipboard
fun ResultScope.resultPointer(value: Any?, type: String?): Result

Convenience overload of resultPointer that returns null when value is null.

Link copied to clipboard

Convenience overload of resultString that returns null when value is null.

Link copied to clipboard
fun ResultScope.resultText(value: Buffer?, encoding: SqliteTextEncoding.ResultText, size: Long = value?.byteSize ?: 0L, cleanup: (Buffer) -> Unit? = null): Result

Convenience overload of resultText that returns null when value is null.

Link copied to clipboard

Convenience overload of resultValue that returns null when value is null.