From 8dabec0d946acab640a31870a70b29f2b87f4619 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Gwendal=20Roue=CC=81?= GRDB 4.2.0 Docs (90% documented) GRDB 4.2.1 Docs (90% documented)
You don’t create a database directly. Instead, you use a DatabaseQueue, or a DatabasePool:
-let dbQueue = DatabaseQueue(...)
+let dbQueue = DatabaseQueue(...)
// The Database is the `db` in the closure:
-try dbQueue.write { db in
- try Player(...).insert(db)
+try dbQueue.write { db in
+ try Player(...).insert(db)
}
@@ -1094,7 +1094,7 @@ a DatabasePool:
@@ -1129,7 +1129,7 @@ a DatabasePool:
@@ -1164,7 +1164,7 @@ a DatabasePool:
@@ -1199,7 +1199,7 @@ a DatabasePool:
@@ -1234,7 +1234,7 @@ a DatabasePool:
@@ -1272,7 +1272,7 @@ underlying database reader.
@@ -1312,7 +1312,7 @@ moment it was created.
@@ -1343,7 +1343,7 @@ moment it was created.
A cursor of database values extracted from a single column.
For example:
-try dbQueue.read { db in
+try dbQueue.read { db in
let urls: DatabaseValueCursor<URL> = try URL.fetchCursor(db, sql: "SELECT url FROM link")
while let url = urls.next() { // URL
print(url)
@@ -1361,7 +1361,7 @@ For example:
@@ -1381,7 +1381,7 @@ For example:
A cursor of optional database values extracted from a single column.
For example:
-try dbQueue.read { db in
+try dbQueue.read { db in
let urls: NullableDatabaseValueCursor<URL> = try Optional<URL>.fetchCursor(db, sql: "SELECT url FROM link")
while let url = urls.next() { // URL?
print(url)
@@ -1399,7 +1399,7 @@ For example:
@@ -1423,11 +1423,11 @@ For example:
A future database value, returned by the DatabaseWriter.concurrentRead(_:)
method.
-let futureCount: Future<Int> = try writer.writeWithoutTransaction { db in
- try Player(...).insert()
+let futureCount: Future<Int> = try writer.writeWithoutTransaction { db in
+ try Player(...).insert()
// Count players concurrently
- return writer.concurrentRead { db in
+ return writer.concurrentRead { db in
return try Player.fetchCount()
}
}
@@ -1446,7 +1446,7 @@ method.
@@ -1480,7 +1480,7 @@ underlying database writer.
@@ -1517,7 +1517,7 @@ underlying database writer.
@@ -1547,7 +1547,7 @@ underlying database writer.
A cursor of database rows. For example:
-try dbQueue.read { db in
+try dbQueue.read { db in
let rows: RowCursor = try Row.fetchCursor(db, sql: "SELECT * FROM player")
}
@@ -1563,7 +1563,7 @@ underlying database writer.
@@ -1601,7 +1601,7 @@ and SelectStatement that fetches rows.
@@ -1633,7 +1633,7 @@ and SelectStatement that fetches rows.
A subclass of Statement that fetches database rows.
You create SelectStatement with the Database.makeSelectStatement() method:
-try dbQueue.read { db in
+try dbQueue.read { db in
let statement = try db.makeSelectStatement(sql: "SELECT COUNT(*) FROM player WHERE score > ?")
let moreThanTwentyCount = try Int.fetchOne(statement, arguments: [20])!
let moreThanThirtyCount = try Int.fetchOne(statement, arguments: [30])!
@@ -1651,7 +1651,7 @@ and SelectStatement that fetches rows.
@@ -1683,7 +1683,7 @@ and SelectStatement that fetches rows.
A subclass of Statement that executes SQL queries.
You create UpdateStatement with the Database.makeUpdateStatement() method:
-try dbQueue.inTransaction { db in
+try dbQueue.inTransaction { db in
let statement = try db.makeUpdateStatement(sql: "INSERT INTO player (name) VALUES (?)")
try statement.execute(arguments: ["Arthur"])
try statement.execute(arguments: ["Barbara"])
@@ -1702,7 +1702,7 @@ and SelectStatement that fetches rows.
@@ -1726,7 +1726,7 @@ and SelectStatement that fetches rows.
A cursor of database values extracted from a single column.
For example:
-try dbQueue.read { db in
+try dbQueue.read { db in
let names: ColumnCursor<String> = try String.fetchCursor(db, sql: "SELECT name FROM player")
while let name = names.next() { // String
print(name)
@@ -1744,7 +1744,7 @@ For example:
@@ -1764,7 +1764,7 @@ For example:
A cursor of optional database values extracted from a single column.
For example:
-try dbQueue.read { db in
+try dbQueue.read { db in
let emails: FastNullableDatabaseValueCursor<String> =
try Optional<String>.fetchCursor(db, sql: "SELECT email FROM player")
while let email = emails.next() { // String?
@@ -1784,7 +1784,7 @@ For example:
@@ -1810,7 +1810,7 @@ For example:
You don’t create instances of this class. Instead, you use the Database
create(virtualTable:using:) method:
-try db.create(virtualTable: "document", using: FTS3()) { t in // t is FTS3TableDefinition
+try db.create(virtualTable: "document", using: FTS3()) { t in // t is FTS3TableDefinition
t.column("content")
}
@@ -1826,7 +1826,7 @@ For example:
@@ -1852,7 +1852,7 @@ For example:
You don’t create instances of this class. Instead, you use the Database
create(virtualTable:using:) method:
-try db.create(virtualTable: "document", using: FTS4()) { t in // t is FTS4TableDefinition
+try db.create(virtualTable: "document", using: FTS4()) { t in // t is FTS4TableDefinition
t.column("content")
}
@@ -1870,7 +1870,7 @@ For example:
@@ -1892,7 +1892,7 @@ For example:
virtual table.
You get instances of this class when you create an FTS4 table:
-try db.create(virtualTable: "document", using: FTS4()) { t in
+try db.create(virtualTable: "document", using: FTS4()) { t in
t.column("content") // FTS4ColumnDefinition
}
@@ -1910,7 +1910,7 @@ virtual table.
@@ -1936,7 +1936,7 @@ virtual table.
You don’t create instances of this class. Instead, you use the Database
create(virtualTable:using:) method:
-try db.create(virtualTable: "document", using: FTS5()) { t in // t is FTS5TableDefinition
+try db.create(virtualTable: "document", using: FTS5()) { t in // t is FTS5TableDefinition
t.column("content")
}
@@ -1965,7 +1965,7 @@ virtual table.
virtual table.
You get instances of this class when you create an FTS5 table:
-try db.create(virtualTable: "document", using: FTS5()) { t in
+try db.create(virtualTable: "document", using: FTS5()) { t in
t.column("content") // FTS5ColumnDefinition
}
@@ -2016,7 +2016,7 @@ virtual table.
@@ -2060,7 +2060,7 @@ virtual table.
@@ -2100,7 +2100,7 @@ virtual table.
@@ -2144,7 +2144,7 @@ virtual table.
@@ -2174,8 +2174,8 @@ virtual table.
A cursor of records. For example:
-struct Player : FetchableRecord { ... }
-try dbQueue.read { db in
+struct Player : FetchableRecord { ... }
+try dbQueue.read { db in
let players: RecordCursor<Player> = try Player.fetchCursor(db, sql: "SELECT * FROM player")
}
@@ -2190,7 +2190,7 @@ virtual table.
@@ -2229,7 +2229,7 @@ more information.
@@ -2272,7 +2272,7 @@ designed to be subclassed.
@@ -2282,7 +2282,7 @@ designed to be subclassed.
diff --git a/docs/4.2/Classes/AnyCursor.html b/docs/4.2/Classes/AnyCursor.html
index 6db7a456d..29bb16aa7 100644
--- a/docs/4.2/Classes/AnyCursor.html
+++ b/docs/4.2/Classes/AnyCursor.html
@@ -14,7 +14,7 @@
- GRDB 4.2.0 Docs (90% documented)
+ GRDB 4.2.1 Docs (90% documented)
@@ -1048,7 +1048,7 @@ the base cursor’s element type
@@ -1079,7 +1079,7 @@ on the base iterator’s element type
@@ -1110,7 +1110,7 @@ on the base sequence’s element type
@@ -1140,7 +1140,7 @@ on the base sequence’s element type
@@ -1150,7 +1150,7 @@ on the base sequence’s element type
diff --git a/docs/4.2/Classes/AnyDatabaseReader.html b/docs/4.2/Classes/AnyDatabaseReader.html
index 38a17751d..f5be6b10d 100644
--- a/docs/4.2/Classes/AnyDatabaseReader.html
+++ b/docs/4.2/Classes/AnyDatabaseReader.html
@@ -14,7 +14,7 @@
- GRDB 4.2.0 Docs (90% documented)
+ GRDB 4.2.1 Docs (90% documented)
@@ -1046,7 +1046,7 @@ underlying database reader.
@@ -1056,7 +1056,7 @@ underlying database reader.
diff --git a/docs/4.2/Classes/AnyDatabaseWriter.html b/docs/4.2/Classes/AnyDatabaseWriter.html
index c023adfb4..cab1b4f94 100644
--- a/docs/4.2/Classes/AnyDatabaseWriter.html
+++ b/docs/4.2/Classes/AnyDatabaseWriter.html
@@ -14,7 +14,7 @@
- GRDB 4.2.0 Docs (90% documented)
+ GRDB 4.2.1 Docs (90% documented)
@@ -1046,7 +1046,7 @@ underlying database writer.
@@ -1056,7 +1056,7 @@ underlying database writer.
diff --git a/docs/4.2/Classes/ColumnDefinition.html b/docs/4.2/Classes/ColumnDefinition.html
index 7497aee6d..7936bcda0 100644
--- a/docs/4.2/Classes/ColumnDefinition.html
+++ b/docs/4.2/Classes/ColumnDefinition.html
@@ -14,7 +14,7 @@
- GRDB 4.2.0 Docs (90% documented)
+ GRDB 4.2.1 Docs (90% documented)
@@ -1103,7 +1103,7 @@
Self so that you can further refine the column definition.
@@ -1164,7 +1164,7 @@
Self so that you can further refine the column definition.
@@ -1225,7 +1225,7 @@
Self so that you can further refine the column definition.
@@ -1266,7 +1266,7 @@
Self so that you can further refine the column definition.
@@ -1286,7 +1286,7 @@
Adds a CHECK constraint on the column.
try db.create(table: "player") { t in
- t.column("name", .text).check { length($0) > 0 }
+ t.column("name", .text).check { length($0) > 0 }
}
@@ -1327,7 +1327,7 @@ represents the defined column, and returns the expression to check.
Self so that you can further refine the column definition.
@@ -1387,7 +1387,7 @@ represents the defined column, and returns the expression to check.
Self so that you can further refine the column definition.
@@ -1447,7 +1447,7 @@ represents the defined column, and returns the expression to check.
Self so that you can further refine the column definition.
@@ -1507,7 +1507,7 @@ represents the defined column, and returns the expression to check.
Self so that you can further refine the column definition.
@@ -1566,7 +1566,7 @@ represents the defined column, and returns the expression to check.
Self so that you can further refine the column definition.
@@ -1625,7 +1625,7 @@ represents the defined column, and returns the expression to check.
Self so that you can further refine the column definition.
@@ -1671,7 +1671,7 @@ represents the defined column, and returns the expression to check.
Self so that you can further refine the column definition.
@@ -1681,7 +1681,7 @@ represents the defined column, and returns the expression to check.
diff --git a/docs/4.2/Classes/Database.html b/docs/4.2/Classes/Database.html
index 312d25d97..7ea4b6d2c 100644
--- a/docs/4.2/Classes/Database.html
+++ b/docs/4.2/Classes/Database.html
@@ -14,7 +14,7 @@
- GRDB 4.2.0 Docs (90% documented)
+ GRDB 4.2.1 Docs (90% documented)
@@ -1016,11 +1016,11 @@
You don’t create a database directly. Instead, you use a DatabaseQueue, or
a DatabasePool:
-let dbQueue = DatabaseQueue(...)
+let dbQueue = DatabaseQueue(...)
// The Database is the `db` in the closure:
-try dbQueue.write { db in
- try Player(...).insert(db)
+try dbQueue.write { db in
+ try Player(...).insert(db)
}
@@ -1060,7 +1060,7 @@ a DatabasePool:
@@ -1108,12 +1108,12 @@ for debugging.
Declaration
Swift
- public static var logError: Database.LogErrorFunction? { get set }
+ public static var logError: Database.LogErrorFunction? { get set }
@@ -1143,7 +1143,7 @@ for debugging.
@@ -1184,12 +1184,12 @@ returns zero.
Declaration
Swift
- public var lastInsertedRowID: Int64 { get }
+ public var lastInsertedRowID: Int64 { get }
@@ -1217,12 +1217,12 @@ successful INSERT, UPDATE or DELETE statement.
Declaration
Swift
- public var changesCount: Int { get }
+ public var changesCount: Int { get }
@@ -1251,12 +1251,12 @@ opened.
Declaration
Swift
- public var totalChangesCount: Int { get }
+ public var totalChangesCount: Int { get }
@@ -1281,12 +1281,12 @@ opened.
Declaration
Swift
- public var isInsideTransaction: Bool { get }
+ public var isInsideTransaction: Bool { get }
@@ -1330,7 +1330,7 @@ modified by another connection.
@@ -1360,7 +1360,7 @@ modified by another connection.
@@ -1394,7 +1394,7 @@ modified by another connection.
@@ -1426,7 +1426,7 @@ modified by another connection.
@@ -1456,7 +1456,7 @@ modified by another connection.
@@ -1486,7 +1486,7 @@ modified by another connection.
@@ -1525,7 +1525,7 @@ table has no explicit primary key, the result is the hidden
@@ -1562,7 +1562,7 @@ table(_:hasUniqueKey:) instead.
@@ -1597,7 +1597,7 @@ if the columns are the primary key, or if there is a unique index on them.
@@ -1627,7 +1627,7 @@ if the columns are the primary key, or if there is a unique index on them.
@@ -1666,7 +1666,7 @@ if the columns are the primary key, or if there is a unique index on them.
@@ -1739,7 +1739,7 @@ if the columns are the primary key, or if there is a unique index on them.
A SelectStatement.
@@ -1804,7 +1804,7 @@ contain values for its eventual arguments.
An UpdateStatement.
@@ -1866,7 +1866,7 @@ contain values for its eventual arguments.
An UpdateStatement.
@@ -1931,7 +1931,7 @@ contain values for its eventual arguments.
An UpdateStatement.
@@ -1973,7 +1973,7 @@ contain values for its eventual arguments.
Declaration
Swift
- public func execute(sql: String, arguments: StatementArguments = StatementArguments()) throws
+ public func execute(sql: String, arguments: StatementArguments = StatementArguments()) throws
@@ -2009,7 +2009,7 @@ contain values for its eventual arguments.
@@ -2028,11 +2028,11 @@ contain values for its eventual arguments.
Executes one or several SQL statements, separated by semi-colons.
-try db.execute(literal: SQLLiteral(
+try db.execute(literal: SQLLiteral(
sql: "INSERT INTO player (name) VALUES (:name)",
arguments: ["name": "Arthur"]))
-try db.execute(literal: SQLLiteral(sql: """
+try db.execute(literal: SQLLiteral(sql: """
INSERT INTO player (name) VALUES (?);
INSERT INTO player (name) VALUES (?);
INSERT INTO player (name) VALUES (?);
@@ -2084,7 +2084,7 @@ without any risk of syntax errors or SQL injection:
@@ -2114,8 +2114,8 @@ without any risk of syntax errors or SQL injection:
Add or redefine an SQL function.
-let fn = DatabaseFunction("succ", argumentCount: 1) { dbValues in
- guard let int = Int.fromDatabaseValue(dbValues[0]) else {
+let fn = DatabaseFunction("succ", argumentCount: 1) { dbValues in
+ guard let int = Int.fromDatabaseValue(dbValues[0]) else {
return nil
}
return int + 1
@@ -2134,7 +2134,7 @@ without any risk of syntax errors or SQL injection:
@@ -2164,7 +2164,7 @@ without any risk of syntax errors or SQL injection:
@@ -2194,7 +2194,7 @@ without any risk of syntax errors or SQL injection:
Add or redefine a collation.
-let collation = DatabaseCollation("localized_standard") { (string1, string2) in
+let collation = DatabaseCollation("localized_standard") { (string1, string2) in
return (string1 as NSString).localizedStandardCompare(string2)
}
db.add(collation: collation)
@@ -2211,7 +2211,7 @@ without any risk of syntax errors or SQL injection:
@@ -2241,7 +2241,7 @@ without any risk of syntax errors or SQL injection:
@@ -2271,8 +2271,8 @@ without any risk of syntax errors or SQL injection:
Executes a block inside a database transaction.
-try dbQueue.inDatabase do {
- try db.inTransaction {
+try dbQueue.inDatabase do {
+ try db.inTransaction {
try db.execute(sql: "INSERT ...")
return .commit
}
@@ -2334,7 +2334,7 @@ for more information.
@@ -2353,8 +2353,8 @@ for more information.
Executes a block inside a savepoint.
-try dbQueue.inDatabase do {
- try db.inSavepoint {
+try dbQueue.inDatabase do {
+ try db.inSavepoint {
try db.execute(sql: "INSERT ...")
return .commit
}
@@ -2401,7 +2401,7 @@ either .commit or .rollback.
@@ -2458,7 +2458,7 @@ for more information.
@@ -2488,7 +2488,7 @@ for more information.
@@ -2518,7 +2518,7 @@ for more information.
@@ -2552,7 +2552,7 @@ for more information.
@@ -2586,8 +2586,8 @@ remains locked for more than the specified duration.
To set the busy mode of a database, use Configuration:
// Wait 1 second before failing with SQLITE_BUSY
-let configuration = Configuration(busyMode: .timeout(1))
-let dbQueue = DatabaseQueue(path: "...", configuration: configuration)
+let configuration = Configuration(busyMode: .timeout(1))
+let dbQueue = DatabaseQueue(path: "...", configuration: configuration)
Relevant SQLite documentation:
@@ -2610,7 +2610,7 @@ remains locked for more than the specified duration.
@@ -2641,7 +2641,7 @@ remains locked for more than the specified duration.
@@ -2674,7 +2674,7 @@ remains locked for more than the specified duration.
@@ -2712,7 +2712,7 @@ remains locked for more than the specified duration.
@@ -2745,7 +2745,7 @@ remains locked for more than the specified duration.
@@ -2778,7 +2778,7 @@ remains locked for more than the specified duration.
@@ -2808,7 +2808,7 @@ remains locked for more than the specified duration.
@@ -2839,7 +2839,7 @@ remains locked for more than the specified duration.
@@ -2870,7 +2870,7 @@ remains locked for more than the specified duration.
@@ -2947,7 +2947,7 @@ is deallocated).
@@ -2977,7 +2977,7 @@ is deallocated).
@@ -2997,8 +2997,8 @@ is deallocated).
Registers a closure to be executed after the next or current
transaction completion.
-try dbQueue.write { db in
- db.afterNextTransactionCommit { _ in
+try dbQueue.write { db in
+ db.afterNextTransactionCommit { _ in
print("success")
}
...
@@ -3020,7 +3020,7 @@ dispatch queue, serialized will all database updates.
@@ -3053,7 +3053,7 @@ dispatch queue, serialized will all database updates.
@@ -3087,7 +3087,7 @@ dispatch queue, serialized will all database updates.
@@ -3255,7 +3255,7 @@ already exists.
@@ -3362,7 +3362,7 @@ already exists.
@@ -3399,7 +3399,7 @@ already exists.
@@ -3471,7 +3471,7 @@ already exists.
@@ -3508,7 +3508,7 @@ already exists.
@@ -3650,7 +3650,7 @@ query.
@@ -3669,7 +3669,7 @@ query.
Creates a partial index.
-try db.create(index: "playerByEmail", on: "player", columns: ["email"], condition: Column("email") != nil)
+try db.create(index: "playerByEmail", on: "player", columns: ["email"], condition: Column("email") != nil)
See https://www.sqlite.org/lang_createindex.html, and
@@ -3772,7 +3772,7 @@ query.
@@ -3809,7 +3809,7 @@ query.
@@ -3849,7 +3849,7 @@ has changed.
@@ -3889,7 +3889,7 @@ has changed.
@@ -3984,7 +3984,7 @@ already exists.
@@ -4014,7 +4014,7 @@ argument: refer to this module’s documentation.
Use this method to create full-text tables using the FTS3, FTS4, or
FTS5 modules:
-try db.create(virtualTable: "book", using: FTS4()) { t in
+try db.create(virtualTable: "book", using: FTS4()) { t in
t.column("title")
t.column("author")
t.column("body")
@@ -4100,7 +4100,7 @@ already exists.
@@ -4110,7 +4110,7 @@ already exists.
diff --git a/docs/4.2/Classes/Database/BusyMode.html b/docs/4.2/Classes/Database/BusyMode.html
index d2312f2b2..b2b31a0e8 100644
--- a/docs/4.2/Classes/Database/BusyMode.html
+++ b/docs/4.2/Classes/Database/BusyMode.html
@@ -14,7 +14,7 @@
- GRDB 4.2.0 Docs (90% documented)
+ GRDB 4.2.1 Docs (90% documented)
@@ -1028,8 +1028,8 @@ remains locked for more than the specified duration.
To set the busy mode of a database, use Configuration:
// Wait 1 second before failing with SQLITE_BUSY
-let configuration = Configuration(busyMode: .timeout(1))
-let dbQueue = DatabaseQueue(path: "...", configuration: configuration)
+let configuration = Configuration(busyMode: .timeout(1))
+let dbQueue = DatabaseQueue(path: "...", configuration: configuration)
Relevant SQLite documentation:
@@ -1071,7 +1071,7 @@ tries to access the locked database.
@@ -1102,7 +1102,7 @@ locked for more than the specified duration (in seconds).
@@ -1133,7 +1133,7 @@ See https://www.sqlite.
@@ -1143,7 +1143,7 @@ See https://www.sqlite.
diff --git a/docs/4.2/Classes/Database/CheckpointMode.html b/docs/4.2/Classes/Database/CheckpointMode.html
index 85ee48afb..f13518009 100644
--- a/docs/4.2/Classes/Database/CheckpointMode.html
+++ b/docs/4.2/Classes/Database/CheckpointMode.html
@@ -14,7 +14,7 @@
- GRDB 4.2.0 Docs (90% documented)
+ GRDB 4.2.1 Docs (90% documented)
@@ -1043,7 +1043,7 @@
@@ -1073,7 +1073,7 @@
@@ -1103,7 +1103,7 @@
@@ -1133,7 +1133,7 @@
@@ -1143,7 +1143,7 @@
diff --git a/docs/4.2/Classes/Database/CollationName.html b/docs/4.2/Classes/Database/CollationName.html
index ddb8a890c..0aebb2141 100644
--- a/docs/4.2/Classes/Database/CollationName.html
+++ b/docs/4.2/Classes/Database/CollationName.html
@@ -14,7 +14,7 @@
- GRDB 4.2.0 Docs (90% documented)
+ GRDB 4.2.1 Docs (90% documented)
@@ -1045,7 +1045,7 @@
@@ -1075,7 +1075,7 @@
@@ -1105,7 +1105,7 @@
@@ -1135,7 +1135,7 @@
@@ -1145,7 +1145,7 @@
diff --git a/docs/4.2/Classes/Database/ColumnType.html b/docs/4.2/Classes/Database/ColumnType.html
index 8f724d0b8..02dd0adab 100644
--- a/docs/4.2/Classes/Database/ColumnType.html
+++ b/docs/4.2/Classes/Database/ColumnType.html
@@ -14,7 +14,7 @@
- GRDB 4.2.0 Docs (90% documented)
+ GRDB 4.2.1 Docs (90% documented)
@@ -1050,7 +1050,7 @@
@@ -1080,7 +1080,7 @@
@@ -1110,7 +1110,7 @@
@@ -1140,7 +1140,7 @@
@@ -1170,7 +1170,7 @@
@@ -1200,7 +1200,7 @@
@@ -1230,7 +1230,7 @@
@@ -1260,7 +1260,7 @@
@@ -1290,7 +1290,7 @@
@@ -1300,7 +1300,7 @@
diff --git a/docs/4.2/Classes/Database/ConflictResolution.html b/docs/4.2/Classes/Database/ConflictResolution.html
index 18d2614e8..b164be0be 100644
--- a/docs/4.2/Classes/Database/ConflictResolution.html
+++ b/docs/4.2/Classes/Database/ConflictResolution.html
@@ -14,7 +14,7 @@
- GRDB 4.2.0 Docs (90% documented)
+ GRDB 4.2.1 Docs (90% documented)
@@ -1045,7 +1045,7 @@
@@ -1075,7 +1075,7 @@
@@ -1105,7 +1105,7 @@
@@ -1135,7 +1135,7 @@
@@ -1165,7 +1165,7 @@
@@ -1175,7 +1175,7 @@
diff --git a/docs/4.2/Classes/Database/ForeignKeyAction.html b/docs/4.2/Classes/Database/ForeignKeyAction.html
index e1a84421d..350a110cd 100644
--- a/docs/4.2/Classes/Database/ForeignKeyAction.html
+++ b/docs/4.2/Classes/Database/ForeignKeyAction.html
@@ -14,7 +14,7 @@
- GRDB 4.2.0 Docs (90% documented)
+ GRDB 4.2.1 Docs (90% documented)
@@ -1045,7 +1045,7 @@
@@ -1075,7 +1075,7 @@
@@ -1105,7 +1105,7 @@
@@ -1135,7 +1135,7 @@
@@ -1145,7 +1145,7 @@
diff --git a/docs/4.2/Classes/Database/TransactionCompletion.html b/docs/4.2/Classes/Database/TransactionCompletion.html
index 17ac6c9d6..516ea72d5 100644
--- a/docs/4.2/Classes/Database/TransactionCompletion.html
+++ b/docs/4.2/Classes/Database/TransactionCompletion.html
@@ -14,7 +14,7 @@
- GRDB 4.2.0 Docs (90% documented)
+ GRDB 4.2.1 Docs (90% documented)
@@ -1043,7 +1043,7 @@
@@ -1073,7 +1073,7 @@
@@ -1083,7 +1083,7 @@
diff --git a/docs/4.2/Classes/Database/TransactionKind.html b/docs/4.2/Classes/Database/TransactionKind.html
index 42730d741..bee5922e3 100644
--- a/docs/4.2/Classes/Database/TransactionKind.html
+++ b/docs/4.2/Classes/Database/TransactionKind.html
@@ -14,7 +14,7 @@
- GRDB 4.2.0 Docs (90% documented)
+ GRDB 4.2.1 Docs (90% documented)
@@ -1043,7 +1043,7 @@
@@ -1073,7 +1073,7 @@
@@ -1103,7 +1103,7 @@
@@ -1113,7 +1113,7 @@
diff --git a/docs/4.2/Classes/Database/TransactionObservationExtent.html b/docs/4.2/Classes/Database/TransactionObservationExtent.html
index 3d3d158e9..d36a62db0 100644
--- a/docs/4.2/Classes/Database/TransactionObservationExtent.html
+++ b/docs/4.2/Classes/Database/TransactionObservationExtent.html
@@ -14,7 +14,7 @@
- GRDB 4.2.0 Docs (90% documented)
+ GRDB 4.2.1 Docs (90% documented)
@@ -1045,7 +1045,7 @@
@@ -1075,7 +1075,7 @@
@@ -1105,7 +1105,7 @@
@@ -1115,7 +1115,7 @@
diff --git a/docs/4.2/Classes/DatabaseCollation.html b/docs/4.2/Classes/DatabaseCollation.html
index c661c4960..20de7e417 100644
--- a/docs/4.2/Classes/DatabaseCollation.html
+++ b/docs/4.2/Classes/DatabaseCollation.html
@@ -14,7 +14,7 @@
- GRDB 4.2.0 Docs (90% documented)
+ GRDB 4.2.1 Docs (90% documented)
@@ -1043,7 +1043,7 @@
@@ -1062,7 +1062,7 @@
Creates a collation.
-let collation = DatabaseCollation("localized_standard") { (string1, string2) in
+let collation = DatabaseCollation("localized_standard") { (string1, string2) in
return (string1 as NSString).localizedStandardCompare(string2)
}
db.add(collation: collation)
@@ -1110,7 +1110,7 @@
@@ -1164,7 +1164,7 @@ connections.
@@ -1207,7 +1207,7 @@ connections.
@@ -1250,7 +1250,7 @@ connections.
@@ -1293,7 +1293,7 @@ connections.
@@ -1336,7 +1336,7 @@ connections.
@@ -1346,7 +1346,7 @@ connections.
diff --git a/docs/4.2/Classes/DatabaseFunction.html b/docs/4.2/Classes/DatabaseFunction.html
index 69f7f66e1..ce79b41c5 100644
--- a/docs/4.2/Classes/DatabaseFunction.html
+++ b/docs/4.2/Classes/DatabaseFunction.html
@@ -14,7 +14,7 @@
- GRDB 4.2.0 Docs (90% documented)
+ GRDB 4.2.1 Docs (90% documented)
@@ -1038,12 +1038,12 @@
Declaration
Swift
- public var name: String { get }
+ public var name: String { get }
@@ -1062,8 +1062,8 @@
Returns an SQL function.
-let fn = DatabaseFunction("succ", argumentCount: 1) { dbValues in
- guard let int = Int.fromDatabaseValue(dbValues[0]) else {
+let fn = DatabaseFunction("succ", argumentCount: 1) { dbValues in
+ guard let int = Int.fromDatabaseValue(dbValues[0]) else {
return nil
}
return int + 1
@@ -1149,7 +1149,7 @@ not nil.
@@ -1168,7 +1168,7 @@ not nil.
Returns an SQL aggregate function.
-struct MySum : DatabaseAggregate {
+struct MySum : DatabaseAggregate {
var sum: Int = 0
mutating func step(_ dbValues: [DatabaseValue]) {
@@ -1177,15 +1177,15 @@ not nil.
}
}
- func finalize() -> DatabaseValueConvertible? {
+ func finalize() -> DatabaseValueConvertible? {
return sum
}
}
-let dbQueue = DatabaseQueue()
-let fn = DatabaseFunction("mysum", argumentCount: 1, aggregate: MySum.self)
+let dbQueue = DatabaseQueue()
+let fn = DatabaseFunction("mysum", argumentCount: 1, aggregate: MySum.self)
dbQueue.add(function: fn)
-try dbQueue.write { db in
+try dbQueue.write { db in
try db.execute(sql: "CREATE TABLE test(i)")
try db.execute(sql: "INSERT INTO test(i) VALUES (1)")
try db.execute(sql: "INSERT INTO test(i) VALUES (2)")
@@ -1270,7 +1270,7 @@ not nil.
@@ -1307,7 +1307,7 @@ String property.
This function is automatically added by GRDB to your database
connections. It is the function used by the query interface’s
capitalized:
-let nameColumn = Column("name")
+let nameColumn = Column("name")
let request = Player.select(nameColumn.capitalized)
let names = try String.fetchAll(dbQueue, request) // [String]
@@ -1322,7 +1322,7 @@ capitalized:
@@ -1348,7 +1348,7 @@ String property.
This function is automatically added by GRDB to your database
connections. It is the function used by the query interface’s
lowercased:
-let nameColumn = Column("name")
+let nameColumn = Column("name")
let request = Player.select(nameColumn.lowercased())
let names = try String.fetchAll(dbQueue, request) // [String]
@@ -1363,7 +1363,7 @@ lowercased:
@@ -1389,7 +1389,7 @@ String property.
This function is automatically added by GRDB to your database
connections. It is the function used by the query interface’s
uppercased:
-let nameColumn = Column("name")
+let nameColumn = Column("name")
let request = Player.select(nameColumn.uppercased())
let names = try String.fetchAll(dbQueue, request) // [String]
@@ -1404,7 +1404,7 @@ uppercased:
@@ -1441,7 +1441,7 @@ localizedCapitalized String property.
This function is automatically added by GRDB to your database
connections. It is the function used by the query interface’s
localizedCapitalized:
-let nameColumn = Column("name")
+let nameColumn = Column("name")
let request = Player.select(nameColumn.localizedCapitalized)
let names = try String.fetchAll(dbQueue, request) // [String]
@@ -1457,7 +1457,7 @@ localizedCapitalized:
@@ -1483,7 +1483,7 @@ localizedLowercased String property.
This function is automatically added by GRDB to your database
connections. It is the function used by the query interface’s
localizedLowercased:
-let nameColumn = Column("name")
+let nameColumn = Column("name")
let request = Player.select(nameColumn.localizedLowercased)
let names = try String.fetchAll(dbQueue, request) // [String]
@@ -1499,7 +1499,7 @@ localizedLowercased:
@@ -1525,7 +1525,7 @@ localizedUppercased String property.
This function is automatically added by GRDB to your database
connections. It is the function used by the query interface’s
localizedUppercased:
-let nameColumn = Column("name")
+let nameColumn = Column("name")
let request = Player.select(nameColumn.localizedUppercased)
let names = try String.fetchAll(dbQueue, request) // [String]
@@ -1541,7 +1541,7 @@ localizedUppercased:
@@ -1584,7 +1584,7 @@ localizedUppercased:
@@ -1594,7 +1594,7 @@ localizedUppercased:
diff --git a/docs/4.2/Classes/DatabaseFuture.html b/docs/4.2/Classes/DatabaseFuture.html
index 22b1bc434..c9a0ec1c8 100644
--- a/docs/4.2/Classes/DatabaseFuture.html
+++ b/docs/4.2/Classes/DatabaseFuture.html
@@ -14,7 +14,7 @@
- GRDB 4.2.0 Docs (90% documented)
+ GRDB 4.2.1 Docs (90% documented)
@@ -1014,11 +1014,11 @@
A future database value, returned by the DatabaseWriter.concurrentRead(_:)
method.
-let futureCount: Future<Int> = try writer.writeWithoutTransaction { db in
- try Player(...).insert()
+let futureCount: Future<Int> = try writer.writeWithoutTransaction { db in
+ try Player(...).insert()
// Count players concurrently
- return writer.concurrentRead { db in
+ return writer.concurrentRead { db in
return try Player.fetchCount()
}
}
@@ -1062,7 +1062,7 @@ method.
@@ -1072,7 +1072,7 @@ method.
diff --git a/docs/4.2/Classes/DatabasePool.html b/docs/4.2/Classes/DatabasePool.html
index f1fa32e99..395e88be4 100644
--- a/docs/4.2/Classes/DatabasePool.html
+++ b/docs/4.2/Classes/DatabasePool.html
@@ -14,7 +14,7 @@
- GRDB 4.2.0 Docs (90% documented)
+ GRDB 4.2.1 Docs (90% documented)
@@ -1045,12 +1045,12 @@
Declaration
Swift
- public var path: String { get }
+ public var path: String { get }
@@ -1074,12 +1074,12 @@
Declaration
Swift
- public var configuration: Configuration { get }
+ public var configuration: Configuration { get }
@@ -1109,7 +1109,7 @@
Opens the SQLite database at path path.
-let dbPool = try DatabasePool(path: "/path/to/database.sqlite")
+let dbPool = try DatabasePool(path: "/path/to/database.sqlite")
Database connections get closed when the database pool gets deallocated.
@@ -1124,7 +1124,7 @@
Declaration
Swift
- public init(path: String, configuration: Configuration = Configuration()) throws
+ public init(path: String, configuration: Configuration = Configuration()) throws
@@ -1160,7 +1160,7 @@
@@ -1224,7 +1224,7 @@ more information.
@@ -1269,7 +1269,7 @@ more information.
@@ -1307,7 +1307,7 @@ enters background.
@@ -1338,21 +1338,21 @@ enters background.
Synchronously executes a read-only block in a protected dispatch queue,
and returns its result. The block is wrapped in a deferred transaction.
-let players = try dbPool.read { db in
+let players = try dbPool.read { db in
try Player.fetchAll(...)
}
The block is completely isolated. Eventual concurrent database updates
are not visible inside the block:
-try dbPool.read { db in
+try dbPool.read { db in
// Those two values are guaranteed to be equal, even if the
// `wine` table is modified between the two requests:
let count1 = try Int.fetchOne(db, sql: "SELECT COUNT(*) FROM wine")!
let count2 = try Int.fetchOne(db, sql: "SELECT COUNT(*) FROM wine")!
}
-try dbPool.read { db in
+try dbPool.read { db in
// Now this value may be different:
let count = try Int.fetchOne(db, sql: "SELECT COUNT(*) FROM wine")!
}
@@ -1395,7 +1395,7 @@ happen while establishing the read access to the database.
@@ -1414,11 +1414,11 @@ happen while establishing the read access to the database.
Asynchronously executes a read-only block in a protected dispatch queue.
-let players = try dbQueue.asyncRead { result in
- do {
+let players = try dbQueue.asyncRead { result in
+ do {
let db = try result.get()
let count = try Player.fetchCount(db)
- } catch {
+ } catch {
// Handle error
}
}
@@ -1457,7 +1457,7 @@ DatabaseError of resultCode SQLITE_READONLY.
@@ -1480,7 +1480,7 @@ and returns its result.
The block argument is not isolated: eventual concurrent database updates
are visible inside the block:
-try dbPool.unsafeRead { db in
+try dbPool.unsafeRead { db in
// Those two values may be different because some other thread
// may have inserted or deleted a wine between the two requests:
let count1 = try Int.fetchOne(db, sql: "SELECT COUNT(*) FROM wine")!
@@ -1489,7 +1489,7 @@ are visible inside the block:
Cursor iteration is safe, though:
-try dbPool.unsafeRead { db in
+try dbPool.unsafeRead { db in
// No concurrent update can mess with this iteration:
let rows = try Row.fetchCursor(db, sql: "SELECT ...")
while let row = try rows.next() { ... }
@@ -1533,7 +1533,7 @@ happen while establishing the read access to the database.
@@ -1556,7 +1556,7 @@ and returns its result.
The block argument is not isolated: eventual concurrent database updates
are visible inside the block:
-try dbPool.unsafeReentrantRead { db in
+try dbPool.unsafeReentrantRead { db in
// Those two values may be different because some other thread
// may have inserted or deleted a wine between the two requests:
let count1 = try Int.fetchOne(db, sql: "SELECT COUNT(*) FROM wine")!
@@ -1565,7 +1565,7 @@ are visible inside the block:
Cursor iteration is safe, though:
-try dbPool.unsafeReentrantRead { db in
+try dbPool.unsafeReentrantRead { db in
// No concurrent update can mess with this iteration:
let rows = try Row.fetchCursor(db, sql: "SELECT ...")
while let row = try rows.next() { ... }
@@ -1610,7 +1610,7 @@ happen while establishing the read access to the database.
@@ -1639,7 +1639,7 @@ happen while establishing the read access to the database.
@@ -1671,23 +1671,23 @@ are established.
In the example below, the number of players is fetched concurrently with
the player insertion. Yet the future is guaranteed to return zero:
-try writer.asyncWriteWithoutTransaction { db in
+try writer.asyncWriteWithoutTransaction { db in
// Delete all players
try Player.deleteAll()
// Count players concurrently
- writer.asyncConcurrentRead { result in
- do {
+ writer.asyncConcurrentRead { result in
+ do {
let db = try result.get()
// Guaranteed to be zero
let count = try Player.fetchCount(db)
- } catch {
+ } catch {
// Handle error
}
}
// Insert a player
- try Player(...).insert(db)
+ try Player(...).insert(db)
}
@@ -1720,7 +1720,7 @@ the player insertion. Yet the future is guaranteed to return zero:
@@ -1794,7 +1794,7 @@ in a transaction.
@@ -1826,7 +1826,7 @@ has completed.
of the database until the transaction has completed.
This method is not reentrant.
-try dbPool.writeInTransaction { db in
+try dbPool.writeInTransaction { db in
db.execute(...)
return .commit
}
@@ -1885,7 +1885,7 @@ for more information.
@@ -1925,7 +1925,7 @@ dangerous concurrency practices.
@@ -1959,7 +1959,7 @@ in a transaction.
@@ -1989,14 +1989,14 @@ in a transaction.
Add or redefine an SQL function.
-let fn = DatabaseFunction("succ", argumentCount: 1) { dbValues in
- guard let int = Int.fromDatabaseValue(dbValues[0]) else {
+let fn = DatabaseFunction("succ", argumentCount: 1) { dbValues in
+ guard let int = Int.fromDatabaseValue(dbValues[0]) else {
return nil
}
return int + 1
}
dbPool.add(function: fn)
-try dbPool.read { db in
+try dbPool.read { db in
try Int.fetchOne(db, sql: "SELECT succ(1)") // 2
}
@@ -2011,7 +2011,7 @@ in a transaction.
@@ -2041,7 +2041,7 @@ in a transaction.
@@ -2071,11 +2071,11 @@ in a transaction.
Add or redefine a collation.
-let collation = DatabaseCollation("localized_standard") { (string1, string2) in
+let collation = DatabaseCollation("localized_standard") { (string1, string2) in
return (string1 as NSString).localizedStandardCompare(string2)
}
dbPool.add(collation: collation)
-try dbPool.write { db in
+try dbPool.write { db in
try db.execute(sql: "CREATE TABLE file (name TEXT COLLATE LOCALIZED_STANDARD")
}
@@ -2090,7 +2090,7 @@ in a transaction.
@@ -2120,7 +2120,7 @@ in a transaction.
@@ -2150,7 +2150,7 @@ in a transaction.
Add a custom FTS5 tokenizer.
-class MyTokenizer : FTS5CustomTokenizer { ... }
+class MyTokenizer : FTS5CustomTokenizer { ... }
dbPool.add(tokenizer: MyTokenizer.self)
@@ -2189,19 +2189,19 @@ moment it was created.
When you want to control the latest committed changes seen by a
snapshot, create it from the pool’s writer protected dispatch queue:
-let snapshot1 = try dbPool.write { db -> DatabaseSnapshot in
+let snapshot1 = try dbPool.write { db -> DatabaseSnapshot in
try Player.deleteAll()
return try dbPool.makeSnapshot()
}
// <- Other threads may modify the database here
let snapshot2 = try dbPool.makeSnapshot()
-try snapshot1.read { db in
+try snapshot1.read { db in
// Guaranteed to be zero
try Player.fetchCount(db)
}
-try snapshot2.read { db in
+try snapshot2.read { db in
// Could be anything
try Player.fetchCount(db)
}
@@ -2210,8 +2210,8 @@ snapshot, create it from the pool’s writer protected dispatch queue:
It is forbidden to create a snapshot from the writer protected dispatch
queue when a transaction is opened, though, because it is likely a
programmer error:
-try dbPool.write { db in
- try db.inTransaction {
+try dbPool.write { db in
+ try db.inTransaction {
try Player.deleteAll()
// fatal error: makeSnapshot() must not be called from inside a transaction
let snapshot = try dbPool.makeSnapshot()
@@ -2222,11 +2222,11 @@ programmer error:
To avoid this fatal error, create the snapshot before or after the
transaction:
-try dbPool.writeWithoutTransaction { db in
+try dbPool.writeWithoutTransaction { db in
// OK
let snapshot = try dbPool.makeSnapshot()
- try db.inTransaction {
+ try db.inTransaction {
try Player.deleteAll()
return .commit
}
@@ -2251,7 +2251,7 @@ number of reader connections in the pool.
@@ -2261,7 +2261,7 @@ number of reader connections in the pool.
diff --git a/docs/4.2/Classes/DatabaseQueue.html b/docs/4.2/Classes/DatabaseQueue.html
index 26df3251d..5aafd886a 100644
--- a/docs/4.2/Classes/DatabaseQueue.html
+++ b/docs/4.2/Classes/DatabaseQueue.html
@@ -14,7 +14,7 @@
- GRDB 4.2.0 Docs (90% documented)
+ GRDB 4.2.1 Docs (90% documented)
@@ -1045,12 +1045,12 @@
Declaration
Swift
- public var configuration: Configuration { get }
+ public var configuration: Configuration { get }
@@ -1075,12 +1075,12 @@
Declaration
Swift
- public var path: String { get }
+ public var path: String { get }
@@ -1110,7 +1110,7 @@
Opens the SQLite database at path path.
-let dbQueue = try DatabaseQueue(path: "/path/to/database.sqlite")
+let dbQueue = try DatabaseQueue(path: "/path/to/database.sqlite")
Database connections get closed when the database queue gets deallocated.
@@ -1125,7 +1125,7 @@
Declaration
Swift
- public init(path: String, configuration: Configuration = Configuration()) throws
+ public init(path: String, configuration: Configuration = Configuration()) throws
@@ -1161,7 +1161,7 @@
@@ -1180,7 +1180,7 @@
Opens an in-memory SQLite database.
-let dbQueue = DatabaseQueue()
+let dbQueue = DatabaseQueue()
Database memory is released when the database queue gets deallocated.
@@ -1190,7 +1190,7 @@
Declaration
Swift
- public init(configuration: Configuration = Configuration())
+ public init(configuration: Configuration = Configuration())
@@ -1214,7 +1214,7 @@
@@ -1259,7 +1259,7 @@
@@ -1297,7 +1297,7 @@ enters background.
@@ -1328,7 +1328,7 @@ enters background.
Synchronously executes a read-only block in a protected dispatch queue,
and returns its result.
-let players = try dbQueue.read { db in
+let players = try dbQueue.read { db in
try Player.fetchAll(db)
}
@@ -1373,7 +1373,7 @@ DatabaseError of resultCode SQLITE_READONLY.
@@ -1392,11 +1392,11 @@ DatabaseError of resultCode SQLITE_READONLY.
Asynchronously executes a read-only block in a protected dispatch queue.
-let players = try dbQueue.asyncRead { result in
- do {
+let players = try dbQueue.asyncRead { result in
+ do {
let db = try result.get()
let count = try Player.fetchCount(db)
- } catch {
+ } catch {
// Handle error
}
}
@@ -1435,7 +1435,7 @@ DatabaseError of resultCode SQLITE_READONLY.
@@ -1464,7 +1464,7 @@ DatabaseError of resultCode SQLITE_READONLY.
@@ -1504,7 +1504,7 @@ also rollbacked, but no error is thrown.
transaction has completed.
This method is not reentrant.
-try dbQueue.writeInTransaction { db in
+try dbQueue.writeInTransaction { db in
db.execute(...)
return .commit
}
@@ -1563,7 +1563,7 @@ for more information.
@@ -1623,7 +1623,7 @@ are completed.
@@ -1644,8 +1644,8 @@ are completed.
Synchronously executes database updates in a protected dispatch queue,
outside of any transaction, and returns the result.
// INSERT INTO player ...
-let players = try dbQueue.inDatabase { db in
- try Player(...).insert(db)
+let players = try dbQueue.inDatabase { db in
+ try Player(...).insert(db)
}
@@ -1685,7 +1685,7 @@ outside of any transaction, and returns the result.
@@ -1706,8 +1706,8 @@ outside of any transaction, and returns the result.
Synchronously executes database updates in a protected dispatch queue, and
returns the result.
// INSERT INTO player ...
-try dbQueue.unsafeReentrantWrite { db in
- try Player(...).insert(db)
+try dbQueue.unsafeReentrantWrite { db in
+ try Player(...).insert(db)
}
@@ -1724,7 +1724,7 @@ concurrency practices.
@@ -1755,7 +1755,7 @@ outside of any transaction.
@@ -1785,14 +1785,14 @@ outside of any transaction.
Add or redefine an SQL function.
-let fn = DatabaseFunction("succ", argumentCount: 1) { dbValues in
- guard let int = Int.fromDatabaseValue(dbValues[0]) else {
+let fn = DatabaseFunction("succ", argumentCount: 1) { dbValues in
+ guard let int = Int.fromDatabaseValue(dbValues[0]) else {
return nil
}
return int + 1
}
dbQueue.add(function: fn)
-try dbQueue.read { db in
+try dbQueue.read { db in
try Int.fetchOne(db, sql: "SELECT succ(1)") // 2
}
@@ -1807,7 +1807,7 @@ outside of any transaction.
@@ -1837,7 +1837,7 @@ outside of any transaction.
@@ -1867,11 +1867,11 @@ outside of any transaction.
Add or redefine a collation.
-let collation = DatabaseCollation("localized_standard") { (string1, string2) in
+let collation = DatabaseCollation("localized_standard") { (string1, string2) in
return (string1 as NSString).localizedStandardCompare(string2)
}
dbQueue.add(collation: collation)
-try dbQueue.write { db in
+try dbQueue.write { db in
try db.execute(sql: "CREATE TABLE file (name TEXT COLLATE LOCALIZED_STANDARD")
}
@@ -1886,7 +1886,7 @@ outside of any transaction.
@@ -1916,7 +1916,7 @@ outside of any transaction.
@@ -1926,7 +1926,7 @@ outside of any transaction.
diff --git a/docs/4.2/Classes/DatabaseSnapshot.html b/docs/4.2/Classes/DatabaseSnapshot.html
index 3808e6639..bbb7d30cd 100644
--- a/docs/4.2/Classes/DatabaseSnapshot.html
+++ b/docs/4.2/Classes/DatabaseSnapshot.html
@@ -14,7 +14,7 @@
- GRDB 4.2.0 Docs (90% documented)
+ GRDB 4.2.1 Docs (90% documented)
@@ -1043,12 +1043,12 @@ moment it was created.
Declaration
Swift
- public var configuration: Configuration { get }
+ public var configuration: Configuration { get }
@@ -1079,7 +1079,7 @@ moment it was created.
Synchronously executes a read-only block that takes a database
connection, and returns its result.
-let players = try snapshot.read { db in
+let players = try snapshot.read { db in
try Player.fetchAll(...)
}
@@ -1118,7 +1118,7 @@ connection, and returns its result.
@@ -1137,11 +1137,11 @@ connection, and returns its result.
Asynchronously executes a read-only block in a protected dispatch queue.
-let players = try snapshot.asyncRead { result in
- do {
+let players = try snapshot.asyncRead { result in
+ do {
let db = try result.get()
let count = try Player.fetchCount(db)
- } catch {
+ } catch {
// Handle error
}
}
@@ -1176,7 +1176,7 @@ connection, and returns its result.
@@ -1216,7 +1216,7 @@ connection, and returns its result.
@@ -1245,7 +1245,7 @@ connection, and returns its result.
@@ -1285,7 +1285,7 @@ connection, and returns its result.
@@ -1314,7 +1314,7 @@ connection, and returns its result.
@@ -1358,7 +1358,7 @@ connection, and returns its result.
@@ -1387,7 +1387,7 @@ connection, and returns its result.
@@ -1397,7 +1397,7 @@ connection, and returns its result.
diff --git a/docs/4.2/Classes/FTS3TableDefinition.html b/docs/4.2/Classes/FTS3TableDefinition.html
index 2b5f66093..ef7be7f40 100644
--- a/docs/4.2/Classes/FTS3TableDefinition.html
+++ b/docs/4.2/Classes/FTS3TableDefinition.html
@@ -14,7 +14,7 @@
- GRDB 4.2.0 Docs (90% documented)
+ GRDB 4.2.1 Docs (90% documented)
@@ -1016,7 +1016,7 @@
You don’t create instances of this class. Instead, you use the Database
create(virtualTable:using:) method:
-try db.create(virtualTable: "document", using: FTS3()) { t in // t is FTS3TableDefinition
+try db.create(virtualTable: "document", using: FTS3()) { t in // t is FTS3TableDefinition
t.column("content")
}
@@ -1039,7 +1039,7 @@
The virtual table tokenizer
-try db.create(virtualTable: "document", using: FTS3()) { t in
+try db.create(virtualTable: "document", using: FTS3()) { t in
t.tokenizer = .porter
}
@@ -1056,7 +1056,7 @@
@@ -1075,7 +1075,7 @@
Appends a table column.
-try db.create(virtualTable: "document", using: FTS3()) { t in
+try db.create(virtualTable: "document", using: FTS3()) { t in
t.column("content")
}
@@ -1109,7 +1109,7 @@
@@ -1119,7 +1119,7 @@
diff --git a/docs/4.2/Classes/FTS4ColumnDefinition.html b/docs/4.2/Classes/FTS4ColumnDefinition.html
index 5771c0896..67a7b1892 100644
--- a/docs/4.2/Classes/FTS4ColumnDefinition.html
+++ b/docs/4.2/Classes/FTS4ColumnDefinition.html
@@ -14,7 +14,7 @@
- GRDB 4.2.0 Docs (90% documented)
+ GRDB 4.2.1 Docs (90% documented)
@@ -1016,7 +1016,7 @@
virtual table.
You get instances of this class when you create an FTS4 table:
-try db.create(virtualTable: "document", using: FTS4()) { t in
+try db.create(virtualTable: "document", using: FTS4()) { t in
t.column("content") // FTS4ColumnDefinition
}
@@ -1041,7 +1041,7 @@ virtual table.
Excludes the column from the full-text index.
-try db.create(virtualTable: "document", using: FTS4()) { t in
+try db.create(virtualTable: "document", using: FTS4()) { t in
t.column("a")
t.column("b").notIndexed()
}
@@ -1065,7 +1065,7 @@ virtual table.
Self so that you can further refine the column definition.
@@ -1084,7 +1084,7 @@ virtual table.
Uses the column as the Int32 language id hidden column.
-try db.create(virtualTable: "document", using: FTS4()) { t in
+try db.create(virtualTable: "document", using: FTS4()) { t in
t.column("a")
t.column("lid").asLanguageId()
}
@@ -1107,7 +1107,7 @@ virtual table.
Self so that you can further refine the column definition.
@@ -1117,7 +1117,7 @@ virtual table.
diff --git a/docs/4.2/Classes/FTS4TableDefinition.html b/docs/4.2/Classes/FTS4TableDefinition.html
index c1898baf9..a5d1f0fb4 100644
--- a/docs/4.2/Classes/FTS4TableDefinition.html
+++ b/docs/4.2/Classes/FTS4TableDefinition.html
@@ -14,7 +14,7 @@
- GRDB 4.2.0 Docs (90% documented)
+ GRDB 4.2.1 Docs (90% documented)
@@ -1016,7 +1016,7 @@
You don’t create instances of this class. Instead, you use the Database
create(virtualTable:using:) method:
-try db.create(virtualTable: "document", using: FTS4()) { t in // t is FTS4TableDefinition
+try db.create(virtualTable: "document", using: FTS4()) { t in // t is FTS4TableDefinition
t.column("content")
}
@@ -1041,7 +1041,7 @@
The virtual table tokenizer
-try db.create(virtualTable: "document", using: FTS4()) { t in
+try db.create(virtualTable: "document", using: FTS4()) { t in
t.tokenizer = .porter
}
@@ -1058,7 +1058,7 @@
@@ -1092,12 +1092,12 @@ established with the
Swift
- public var content: String? { get set }
+ public var content: String? { get set }
@@ -1129,7 +1129,7 @@ established with the
- Show on GitHub
+ Show on GitHub
@@ -1161,7 +1161,7 @@ established with the
- Show on GitHub
+ Show on GitHub
@@ -1193,7 +1193,7 @@ established with the
- Show on GitHub
+ Show on GitHub
@@ -1213,7 +1213,7 @@ established with the
Support for the FTS5 prefix option
// CREATE VIRTUAL TABLE document USING FTS4(content, prefix='2 4');
-db.create(virtualTable: "document", using:FTS4()) { t in
+db.create(virtualTable: "document", using:FTS4()) { t in
t.prefixes = [2, 4]
t.column("content")
}
@@ -1231,7 +1231,7 @@ established with the
- Show on GitHub
+ Show on GitHub
@@ -1250,7 +1250,7 @@ established with the
Appends a table column.
-try db.create(virtualTable: "document", using: FTS4()) { t in
+try db.create(virtualTable: "document", using: FTS4()) { t in
t.column("content")
}
@@ -1285,7 +1285,7 @@ established with the
- Show on GitHub
+ Show on GitHub
@@ -1322,7 +1322,7 @@ full-text table is kept up to date with the external table.
@@ -1332,7 +1332,7 @@ full-text table is kept up to date with the external table.
diff --git a/docs/4.2/Classes/FTS5ColumnDefinition.html b/docs/4.2/Classes/FTS5ColumnDefinition.html
index 3a70a3c40..400408065 100644
--- a/docs/4.2/Classes/FTS5ColumnDefinition.html
+++ b/docs/4.2/Classes/FTS5ColumnDefinition.html
@@ -14,7 +14,7 @@
- GRDB 4.2.0 Docs (90% documented)
+ GRDB 4.2.1 Docs (90% documented)
@@ -1010,7 +1010,7 @@
virtual table.
You get instances of this class when you create an FTS5 table:
-try db.create(virtualTable: "document", using: FTS5()) { t in
+try db.create(virtualTable: "document", using: FTS5()) { t in
t.column("content") // FTS5ColumnDefinition
}
@@ -1035,7 +1035,7 @@ virtual table.
Excludes the column from the full-text index.
-try db.create(virtualTable: "document", using: FTS5()) { t in
+try db.create(virtualTable: "document", using: FTS5()) { t in
t.column("a")
t.column("b").notIndexed()
}
@@ -1052,7 +1052,7 @@ virtual table.
diff --git a/docs/4.2/Classes/FTS5TableDefinition.html b/docs/4.2/Classes/FTS5TableDefinition.html
index 6e51ea535..923a003d1 100644
--- a/docs/4.2/Classes/FTS5TableDefinition.html
+++ b/docs/4.2/Classes/FTS5TableDefinition.html
@@ -14,7 +14,7 @@
- GRDB 4.2.0 Docs (90% documented)
+ GRDB 4.2.1 Docs (90% documented)
@@ -1010,7 +1010,7 @@
You don’t create instances of this class. Instead, you use the Database
create(virtualTable:using:) method:
-try db.create(virtualTable: "document", using: FTS5()) { t in // t is FTS5TableDefinition
+try db.create(virtualTable: "document", using: FTS5()) { t in // t is FTS5TableDefinition
t.column("content")
}
@@ -1035,7 +1035,7 @@
The virtual table tokenizer
-try db.create(virtualTable: "document", using: FTS5()) { t in
+try db.create(virtualTable: "document", using: FTS5()) { t in
t.tokenizer = .porter()
}
@@ -1179,7 +1179,7 @@ established with the
Appends a table column.
-try db.create(virtualTable: "document", using: FTS5()) { t in
+try db.create(virtualTable: "document", using: FTS5()) { t in
t.column("content")
}
@@ -1219,7 +1219,7 @@ full-text table is kept up to date with the external table.
diff --git a/docs/4.2/Classes/FetchedRecordsController.html b/docs/4.2/Classes/FetchedRecordsController.html
index 74cad8960..c0ff8c2dc 100644
--- a/docs/4.2/Classes/FetchedRecordsController.html
+++ b/docs/4.2/Classes/FetchedRecordsController.html
@@ -14,7 +14,7 @@
- GRDB 4.2.0 Docs (90% documented)
+ GRDB 4.2.1 Docs (90% documented)
@@ -1059,7 +1059,7 @@ its eventual arguments.
public convenience init(
_ databaseWriter: DatabaseWriter,
sql: String,
- arguments: StatementArguments = StatementArguments(),
+ arguments: StatementArguments = StatementArguments(),
adapter: RowAdapter? = nil,
queue: DispatchQueue = .main,
isSameRecord: ((Record, Record) -> Bool)? = nil) throws
@@ -1153,7 +1153,7 @@ same identity. For example, they have the same id.
@@ -1173,8 +1173,8 @@ same identity. For example, they have the same id.
Creates a fetched records controller initialized from a fetch request
from the Query Interface.
-let request = Wine.order(Column("name"))
-let controller = FetchedRecordsController(
+let request = Wine.order(Column("name"))
+let controller = FetchedRecordsController(
dbQueue,
request: request,
isSameRecord: { (wine1, wine2) in wine1.id == wine2.id })
@@ -1257,7 +1257,7 @@ same identity. For example, they have the same id.
@@ -1293,7 +1293,7 @@ main queue unless stated otherwise in the controller’s initializer).
@@ -1337,7 +1337,7 @@ to changes.
@@ -1369,7 +1369,7 @@ to changes.
@@ -1405,7 +1405,7 @@ main queue unless stated otherwise in the controller’s initializer).
@@ -1436,14 +1436,14 @@ main queue unless stated otherwise in the controller’s initializer).
Swift
public func setRequest(
sql: String,
- arguments: StatementArguments = StatementArguments(),
+ arguments: StatementArguments = StatementArguments(),
adapter: RowAdapter? = nil)
throws
@@ -1523,7 +1523,7 @@ removed, moved, or updated.
@@ -1621,7 +1621,7 @@ removed, moved, or updated.
@@ -1662,7 +1662,7 @@ main queue unless stated otherwise in the controller’s initializer).
@@ -1699,7 +1699,7 @@ after the didChange callback has completed.
@@ -1749,7 +1749,7 @@ main queue unless stated otherwise in the controller’s initializer).
@@ -1805,7 +1805,7 @@ has an id primary key, this initializer is equivalent to:
public convenience init(
_ databaseWriter: DatabaseWriter,
sql: String,
- arguments: StatementArguments = StatementArguments(),
+ arguments: StatementArguments = StatementArguments(),
adapter: RowAdapter? = nil,
queue: DispatchQueue = .main) throws
@@ -1883,7 +1883,7 @@ used from this queue.
@@ -1903,8 +1903,8 @@ used from this queue.
Creates a fetched records controller initialized from a fetch request
from the Query Interface.
-let request = Wine.order(Column("name"))
-let controller = FetchedRecordsController(
+let request = Wine.order(Column("name"))
+let controller = FetchedRecordsController(
dbQueue,
request: request)
@@ -1980,7 +1980,7 @@ used from this queue.
@@ -2043,7 +2043,7 @@ records, a fatal error is raised.
@@ -2090,7 +2090,7 @@ records. In this case, there is a single empty section.
@@ -2136,7 +2136,7 @@ records. In this case, there is a single empty section.
if record could not be found.
@@ -2146,7 +2146,7 @@ if record could not be found.
diff --git a/docs/4.2/Classes/Record.html b/docs/4.2/Classes/Record.html
index 436807b51..c5e613d09 100644
--- a/docs/4.2/Classes/Record.html
+++ b/docs/4.2/Classes/Record.html
@@ -14,7 +14,7 @@
- GRDB 4.2.0 Docs (90% documented)
+ GRDB 4.2.1 Docs (90% documented)
@@ -1051,7 +1051,7 @@ designed to be subclassed.
@@ -1081,7 +1081,7 @@ designed to be subclassed.
@@ -1114,8 +1114,8 @@ designed to be subclassed.
This table name is required by the insert, update, save, delete,
and exists methods.
-class Player : Record {
- override class var databaseTableName: String {
+class Player : Record {
+ override class var databaseTableName: String {
return "player"
}
}
@@ -1128,7 +1128,7 @@ and exists methods.
Declaration
Swift
- open class var databaseTableName: String { get }
+ open class var databaseTableName: String { get }
@@ -1137,7 +1137,7 @@ and exists methods.
The name of a database table.
@@ -1173,12 +1173,12 @@ even if a row was actually inserted without any conflict.
Declaration
Swift
- open class var persistenceConflictPolicy: PersistenceConflictPolicy { get }
+ open class var persistenceConflictPolicy: PersistenceConflictPolicy { get }
@@ -1205,9 +1205,9 @@ even if a row was actually inserted without any conflict.
You can override this property and provide an explicit list
of columns:
-class RestrictedPlayer : Record {
+class RestrictedPlayer : Record {
override static var databaseSelection: [SQLSelectable] {
- return [Column("id"), Column("name")]
+ return [Column("id"), Column("name")]
}
}
@@ -1216,9 +1216,9 @@ of columns:
You can also add extra columns such as the rowid column:
-class ExtendedPlayer : Player {
+class ExtendedPlayer : Player {
override static var databaseSelection: [SQLSelectable] {
- return [AllColumns(), Column.rowID]
+ return [AllColumns(), Column.rowID]
}
}
@@ -1236,7 +1236,7 @@ of columns:
@@ -1260,7 +1260,7 @@ of columns:
the columns of the database table (see Record.databaseTableName()).
Primary key columns, if any, must be included.
-class Player : Record {
+class Player : Record {
var id: Int64?
var name: String?
@@ -1284,7 +1284,7 @@ the container.
@@ -1309,7 +1309,7 @@ dispatch queue, with the inserted RowID and the eventual
INTEGER PRIMARY KEY column name.
The implementation of the base Record class does nothing.
-class Player : Record {
+class Player : Record {
var id: Int64?
var name: String?
@@ -1360,7 +1360,7 @@ INTEGER PRIMARY KEY column name.
@@ -1409,7 +1409,7 @@ INTEGER PRIMARY KEY column name.
A copy of self.
@@ -1460,12 +1460,12 @@ of the record.
Declaration
Swift
- public var hasDatabaseChanges: Bool { get set }
+ public var hasDatabaseChanges: Bool { get set }
@@ -1503,7 +1503,7 @@ are nil.
@@ -1577,7 +1577,7 @@ before the insertion.
@@ -1650,7 +1650,7 @@ match any row in the database and record could not be updated.
@@ -1729,7 +1729,7 @@ match any row in the database and record could not be updated.
Whether the record had changes.
@@ -1798,7 +1798,7 @@ thrown by update().
@@ -1859,7 +1859,7 @@ thrown by update().
Whether a database row was deleted.
@@ -1869,7 +1869,7 @@ thrown by update().
diff --git a/docs/4.2/Classes/Row.html b/docs/4.2/Classes/Row.html
index 4da6b1ae2..8f7d49bbe 100644
--- a/docs/4.2/Classes/Row.html
+++ b/docs/4.2/Classes/Row.html
@@ -14,7 +14,7 @@
- GRDB 4.2.0 Docs (90% documented)
+ GRDB 4.2.1 Docs (90% documented)
@@ -1045,7 +1045,7 @@
@@ -1087,7 +1087,7 @@
@@ -1128,7 +1128,7 @@
@@ -1158,7 +1158,7 @@
@@ -1191,7 +1191,7 @@ adopt DatabaseValueConvertible.
@@ -1225,7 +1225,7 @@ want to keep a specific one: row.copy().
@@ -1269,7 +1269,7 @@ of column-value pairs in self.
@@ -1301,7 +1301,7 @@ of column-value pairs in self.
@@ -1347,12 +1347,12 @@ contains a non-null value.
Declaration
Swift
- public var containsNonNullValue: Bool { get }
+ public var containsNonNullValue: Bool { get }
@@ -1389,7 +1389,7 @@ values.
@@ -1418,12 +1418,12 @@ righmost column.
Declaration
Swift
- public subscript(index: Int) -> DatabaseValueConvertible? { get }
+ public subscript(index: Int) -> DatabaseValueConvertible? { get }
@@ -1456,12 +1456,12 @@ fail, a fatal error is raised.
Swift
@inlinable
-public subscript<Value>(index: Int) -> Value? where Value : DatabaseValueConvertible { get }
+public subscript<Value>(index: Int) -> Value? where Value : DatabaseValueConvertible { get }
@@ -1498,12 +1498,12 @@ StatementColumnConvertible. It may trigger SQLite built-in conversions
Swift
@inlinable
-public subscript<Value>(index: Int) -> Value? where Value : DatabaseValueConvertible, Value : StatementColumnConvertible { get }
+public subscript<Value>(index: Int) -> Value? where Value : DatabaseValueConvertible, Value : StatementColumnConvertible { get }
@@ -1535,12 +1535,12 @@ SQLite value can not be converted to Value.
Swift
@inlinable
-public subscript<Value>(index: Int) -> Value where Value : DatabaseValueConvertible { get }
+public subscript<Value>(index: Int) -> Value where Value : DatabaseValueConvertible { get }
@@ -1576,12 +1576,12 @@ StatementColumnConvertible. It may trigger SQLite built-in conversions
Swift
@inlinable
-public subscript<Value>(index: Int) -> Value where Value : DatabaseValueConvertible, Value : StatementColumnConvertible { get }
+public subscript<Value>(index: Int) -> Value where Value : DatabaseValueConvertible, Value : StatementColumnConvertible { get }
@@ -1612,12 +1612,12 @@ the same name, the leftmost column is considered.
Declaration
Swift
- public subscript(columnName: String) -> DatabaseValueConvertible? { get }
+ public subscript(columnName: String) -> DatabaseValueConvertible? { get }
@@ -1650,12 +1650,12 @@ nil. Otherwise the SQLite value is converted to the requested type
Swift
@inlinable
-public subscript<Value>(columnName: String) -> Value? where Value : DatabaseValueConvertible { get }
+public subscript<Value>(columnName: String) -> Value? where Value : DatabaseValueConvertible { get }
@@ -1692,12 +1692,12 @@ StatementColumnConvertible. It may trigger SQLite built-in conversions
Swift
@inlinable
-public subscript<Value>(columnName: String) -> Value? where Value : DatabaseValueConvertible, Value : StatementColumnConvertible { get }
+public subscript<Value>(columnName: String) -> Value? where Value : DatabaseValueConvertible, Value : StatementColumnConvertible { get }
@@ -1731,12 +1731,12 @@ SQLite value can not be converted to Value.
Swift
@inlinable
-public subscript<Value>(columnName: String) -> Value where Value : DatabaseValueConvertible { get }
+public subscript<Value>(columnName: String) -> Value where Value : DatabaseValueConvertible { get }
@@ -1774,12 +1774,12 @@ StatementColumnConvertible. It may trigger SQLite built-in conversions
Swift
@inlinable
-public subscript<Value>(columnName: String) -> Value where Value : DatabaseValueConvertible, Value : StatementColumnConvertible { get }
+public subscript<Value>(columnName: String) -> Value where Value : DatabaseValueConvertible, Value : StatementColumnConvertible { get }
@@ -1811,12 +1811,12 @@ the same name, the leftmost column is considered.
Swift
@inlinable
-public subscript<Column>(column: Column) -> DatabaseValueConvertible? where Column : ColumnExpression { get }
+public subscript<Column>(column: Column) -> DatabaseValueConvertible? where Column : ColumnExpression { get }
@@ -1849,12 +1849,12 @@ nil. Otherwise the SQLite value is converted to the requested type
Swift
@inlinable
-public subscript<Value, Column>(column: Column) -> Value? where Value : DatabaseValueConvertible, Column : ColumnExpression { get }
+public subscript<Value, Column>(column: Column) -> Value? where Value : DatabaseValueConvertible, Column : ColumnExpression { get }
@@ -1900,7 +1900,7 @@ StatementColumnConvertible. It may trigger SQLite built-in conversions
@@ -1934,12 +1934,12 @@ SQLite value can not be converted to Value.
Swift
@inlinable
-public subscript<Value, Column>(column: Column) -> Value where Value : DatabaseValueConvertible, Column : ColumnExpression { get }
+public subscript<Value, Column>(column: Column) -> Value where Value : DatabaseValueConvertible, Column : ColumnExpression { get }
@@ -1986,7 +1986,7 @@ StatementColumnConvertible. It may trigger SQLite built-in conversions
@@ -2025,7 +2025,7 @@ than the row’s lifetime.
@@ -2065,7 +2065,7 @@ than the row’s lifetime.
@@ -2105,7 +2105,7 @@ than the row’s lifetime.
@@ -2149,7 +2149,7 @@ of column-value pairs in self.
@@ -2184,7 +2184,7 @@ of column-value pairs in self.
let request = Book.including(required: Book.author)
let row = try Row.fetchOne(db, request)!
-print(Book(row: row).title)
+print(Book(row: row).title)
// Prints "Moby-Dick"
let author: Author = row["author"]
@@ -2196,7 +2196,7 @@ of column-value pairs in self.
let request = Book.including(required: Book.author.including(required: Author.country))
let row = try Row.fetchOne(db, request)!
-print(Book(row: row).title)
+print(Book(row: row).title)
// Prints "Moby-Dick"
let country: Country = row["country"]
@@ -2215,12 +2215,12 @@ for more information.
Declaration
Swift
- public subscript<Record>(scope: String) -> Record where Record : FetchableRecord { get }
+ public subscript<Record>(scope: String) -> Record where Record : FetchableRecord { get }
@@ -2244,7 +2244,7 @@ for more information.
let request = Book.including(optional: Book.author)
let row = try Row.fetchOne(db, request)!
-print(Book(row: row).title)
+print(Book(row: row).title)
// Prints "Moby-Dick"
let author: Author? = row["author"]
@@ -2256,7 +2256,7 @@ for more information.
let request = Book.including(optional: Book.author.including(optional: Author.country))
let row = try Row.fetchOne(db, request)!
-print(Book(row: row).title)
+print(Book(row: row).title)
// Prints "Moby-Dick"
let country: Country? = row["country"]
@@ -2275,12 +2275,12 @@ for more information.
Declaration
Swift
- public subscript<Record>(scope: String) -> Record? where Record : FetchableRecord { get }
+ public subscript<Record>(scope: String) -> Record? where Record : FetchableRecord { get }
@@ -2304,7 +2304,7 @@ for more information.
let request = Author.including(all: Author.books)
let row = try Row.fetchOne(db, request)!
-print(Author(row: row).name)
+print(Author(row: row).name)
// Prints "Herman Melville"
let books: [Book] = row["books"]
@@ -2326,7 +2326,7 @@ for more information.
@@ -2350,7 +2350,7 @@ for more information.
let request = Author.including(all: Author.books)
let row = try Row.fetchOne(db, request)!
-print(Author(row: row).name)
+print(Author(row: row).name)
// Prints "Herman Melville"
let books: Set<Book> = row["books"]
@@ -2363,12 +2363,12 @@ for more information.
Declaration
Swift
- public subscript<Record>(key: String) -> Set<Record> where Record : FetchableRecord, Record : Hashable { get }
+ public subscript<Record>(key: String) -> Set<Record> where Record : FetchableRecord, Record : Hashable { get }
@@ -2401,10 +2401,10 @@ for more information.
For example:
// Define a tree of nested scopes
-let adapter = ScopeAdapter([
- "foo": RangeRowAdapter(0..<1),
- "bar": RangeRowAdapter(1..<2).addingScopes([
- "baz" : RangeRowAdapter(2..<3)])])
+let adapter = ScopeAdapter([
+ "foo": RangeRowAdapter(0..<1),
+ "bar": RangeRowAdapter(1..<2).addingScopes([
+ "baz" : RangeRowAdapter(2..<3)])])
// Fetch
let sql = "SELECT 1 AS foo, 2 AS bar, 3 AS baz"
@@ -2423,12 +2423,12 @@ for more information.
Declaration
@@ -2450,10 +2450,10 @@ for more information.
For example:
// Define a tree of nested scopes
-let adapter = ScopeAdapter([
- "foo": RangeRowAdapter(0..<1),
- "bar": RangeRowAdapter(1..<2).addingScopes([
- "baz" : RangeRowAdapter(2..<3)])])
+let adapter = ScopeAdapter([
+ "foo": RangeRowAdapter(0..<1),
+ "bar": RangeRowAdapter(1..<2).addingScopes([
+ "baz" : RangeRowAdapter(2..<3)])])
// Fetch
let sql = "SELECT 1 AS foo, 2 AS bar, 3 AS baz"
@@ -2471,12 +2471,12 @@ for more information.
Declaration
Swift
- public var scopesTree: ScopesTreeView { get }
+ public var scopesTree: ScopesTreeView { get }
@@ -2500,9 +2500,9 @@ for more information.
adapted rows, such as rows fetched from joined requests.
let row = ...
// Failure because row equality tests for row scopes:
-XCTAssertEqual(row, ["id": 1, "name": "foo"])
+XCTAssertEqual(row, ["id": 1, "name": "foo"])
// Success:
-XCTAssertEqual(row.unscoped, ["id": 1, "name": "foo"])
+XCTAssertEqual(row.unscoped, ["id": 1, "name": "foo"])
@@ -2510,12 +2510,12 @@ adapted rows, such as rows fetched from joined requests.
Declaration
Swift
- public var unscoped: Row { get }
+ public var unscoped: Row { get }
@@ -2543,12 +2543,12 @@ adapted rows, such as rows fetched from joined requests.
Declaration
Swift
- public var unadapted: Row { get }
+ public var unadapted: Row { get }
@@ -2677,7 +2677,7 @@ elements are undefined.
A cursor over fetched rows.
@@ -2766,7 +2766,7 @@ elements are undefined.
An array of rows.
@@ -2855,7 +2855,7 @@ elements are undefined.
An optional row.
@@ -2918,7 +2918,7 @@ elements are undefined.
public static func fetchCursor(
_ db: Database,
sql: String,
- arguments: StatementArguments = StatementArguments(),
+ arguments: StatementArguments = StatementArguments(),
adapter: RowAdapter? = nil)
throws -> RowCursor
@@ -2984,7 +2984,7 @@ elements are undefined.
A cursor over fetched rows.
@@ -3004,7 +3004,7 @@ elements are undefined.
Returns an array of rows fetched from an SQL query.
let rows = try Row.fetchAll(db, sql: "SELECT id, name FROM player") // [Row]
-for row in rows {
+for row in rows {
let id: Int64 = row[0]
let name: String = row[1]
}
@@ -3023,7 +3023,7 @@ elements are undefined.
public static func fetchAll(
_ db: Database,
sql: String,
- arguments: StatementArguments = StatementArguments(),
+ arguments: StatementArguments = StatementArguments(),
adapter: RowAdapter? = nil)
throws -> [Row]
@@ -3089,7 +3089,7 @@ elements are undefined.
An array of rows.
@@ -3109,7 +3109,7 @@ elements are undefined.
Returns a single row fetched from an SQL query.
let row = try Row.fetchOne(db, sql: "SELECT id, name FROM player") // Row?
-if let row = row {
+if let row = row {
let id: Int64 = row[0]
let name: String = row[1]
}
@@ -3128,7 +3128,7 @@ elements are undefined.
public static func fetchOne(
_ db: Database,
sql: String,
- arguments: StatementArguments = StatementArguments(),
+ arguments: StatementArguments = StatementArguments(),
adapter: RowAdapter? = nil)
throws -> Row?
@@ -3194,7 +3194,7 @@ elements are undefined.
An optional row.
@@ -3295,7 +3295,7 @@ elements are undefined.
A cursor over fetched rows.
@@ -3368,7 +3368,7 @@ elements are undefined.
An array of rows.
@@ -3441,7 +3441,7 @@ elements are undefined.
An optional row.
@@ -3487,7 +3487,7 @@ duplicated columns names are allowed.
@@ -3528,7 +3528,7 @@ duplicated columns names are allowed.
@@ -3563,10 +3563,10 @@ dictionary.
For example:
// Define a tree of nested scopes
-let adapter = ScopeAdapter([
- "foo": RangeRowAdapter(0..<1),
- "bar": RangeRowAdapter(1..<2).addingScopes([
- "baz" : RangeRowAdapter(2..<3)])])
+let adapter = ScopeAdapter([
+ "foo": RangeRowAdapter(0..<1),
+ "bar": RangeRowAdapter(1..<2).addingScopes([
+ "baz" : RangeRowAdapter(2..<3)])])
// Fetch
let sql = "SELECT 1 AS foo, 2 AS bar, 3 AS baz"
@@ -3591,7 +3591,7 @@ dictionary.
@@ -3624,10 +3624,10 @@ dictionary.
For example:
// Define a tree of nested scopes
-let adapter = ScopeAdapter([
- "foo": RangeRowAdapter(0..<1),
- "bar": RangeRowAdapter(1..<2).addingScopes([
- "baz" : RangeRowAdapter(2..<3)])])
+let adapter = ScopeAdapter([
+ "foo": RangeRowAdapter(0..<1),
+ "bar": RangeRowAdapter(1..<2).addingScopes([
+ "baz" : RangeRowAdapter(2..<3)])])
// Fetch
let sql = "SELECT 1 AS foo, 2 AS bar, 3 AS baz"
@@ -3651,7 +3651,7 @@ dictionary.
@@ -3705,7 +3705,7 @@ dictionary.
@@ -3715,7 +3715,7 @@ dictionary.
diff --git a/docs/4.2/Classes/Row/PrefetchedRowsView.html b/docs/4.2/Classes/Row/PrefetchedRowsView.html
index 36e62325f..f8c02ee42 100644
--- a/docs/4.2/Classes/Row/PrefetchedRowsView.html
+++ b/docs/4.2/Classes/Row/PrefetchedRowsView.html
@@ -14,7 +14,7 @@
- GRDB 4.2.0 Docs (90% documented)
+ GRDB 4.2.1 Docs (90% documented)
@@ -1050,12 +1050,12 @@
Declaration
Swift
- public var isEmpty: Bool { get }
+ public var isEmpty: Bool { get }
@@ -1093,7 +1093,7 @@
@@ -1140,7 +1140,7 @@ available, too.
@@ -1150,7 +1150,7 @@ available, too.
diff --git a/docs/4.2/Classes/Row/ScopesTreeView.html b/docs/4.2/Classes/Row/ScopesTreeView.html
index e4604faec..151c43863 100644
--- a/docs/4.2/Classes/Row/ScopesTreeView.html
+++ b/docs/4.2/Classes/Row/ScopesTreeView.html
@@ -14,7 +14,7 @@
- GRDB 4.2.0 Docs (90% documented)
+ GRDB 4.2.1 Docs (90% documented)
@@ -1016,10 +1016,10 @@
For example:
// Define a tree of nested scopes
-let adapter = ScopeAdapter([
- "foo": RangeRowAdapter(0..<1),
- "bar": RangeRowAdapter(1..<2).addingScopes([
- "baz" : RangeRowAdapter(2..<3)])])
+let adapter = ScopeAdapter([
+ "foo": RangeRowAdapter(0..<1),
+ "bar": RangeRowAdapter(1..<2).addingScopes([
+ "baz" : RangeRowAdapter(2..<3)])])
// Fetch
let sql = "SELECT 1 AS foo, 2 AS bar, 3 AS baz"
@@ -1061,7 +1061,7 @@
@@ -1112,12 +1112,12 @@
Declaration
Swift
- public subscript(name: String) -> Row? { get }
+ public subscript(name: String) -> Row? { get }
@@ -1127,7 +1127,7 @@
diff --git a/docs/4.2/Classes/Row/ScopesView.html b/docs/4.2/Classes/Row/ScopesView.html
index 5f642de51..746209d11 100644
--- a/docs/4.2/Classes/Row/ScopesView.html
+++ b/docs/4.2/Classes/Row/ScopesView.html
@@ -14,7 +14,7 @@
- GRDB 4.2.0 Docs (90% documented)
+ GRDB 4.2.1 Docs (90% documented)
@@ -1018,10 +1018,10 @@ dictionary.
For example:
// Define a tree of nested scopes
-let adapter = ScopeAdapter([
- "foo": RangeRowAdapter(0..<1),
- "bar": RangeRowAdapter(1..<2).addingScopes([
- "baz" : RangeRowAdapter(2..<3)])])
+let adapter = ScopeAdapter([
+ "foo": RangeRowAdapter(0..<1),
+ "bar": RangeRowAdapter(1..<2).addingScopes([
+ "baz" : RangeRowAdapter(2..<3)])])
// Fetch
let sql = "SELECT 1 AS foo, 2 AS bar, 3 AS baz"
@@ -1063,7 +1063,7 @@ dictionary.
@@ -1088,12 +1088,12 @@ dictionary.
Declaration
Swift
- public var names: Dictionary<String, LayoutedRowAdapter>.Keys { get }
+ public var names: Dictionary<String, LayoutedRowAdapter>.Keys { get }
@@ -1119,12 +1119,12 @@ scope is not defined.
Declaration
Swift
- public subscript(name: String) -> Row? { get }
+ public subscript(name: String) -> Row? { get }
@@ -1134,7 +1134,7 @@ scope is not defined.
diff --git a/docs/4.2/Classes/RowCursor.html b/docs/4.2/Classes/RowCursor.html
index 66a593328..80ecebae5 100644
--- a/docs/4.2/Classes/RowCursor.html
+++ b/docs/4.2/Classes/RowCursor.html
@@ -14,7 +14,7 @@
- GRDB 4.2.0 Docs (90% documented)
+ GRDB 4.2.1 Docs (90% documented)
@@ -1013,7 +1013,7 @@
A cursor of database rows. For example:
-try dbQueue.read { db in
+try dbQueue.read { db in
let rows: RowCursor = try Row.fetchCursor(db, sql: "SELECT * FROM player")
}
@@ -1047,7 +1047,7 @@
@@ -1057,7 +1057,7 @@
diff --git a/docs/4.2/Classes/SelectStatement.html b/docs/4.2/Classes/SelectStatement.html
index dc3906cf6..d5fa7a819 100644
--- a/docs/4.2/Classes/SelectStatement.html
+++ b/docs/4.2/Classes/SelectStatement.html
@@ -14,7 +14,7 @@
- GRDB 4.2.0 Docs (90% documented)
+ GRDB 4.2.1 Docs (90% documented)
@@ -1015,7 +1015,7 @@
A subclass of Statement that fetches database rows.
You create SelectStatement with the Database.makeSelectStatement() method:
-try dbQueue.read { db in
+try dbQueue.read { db in
let statement = try db.makeSelectStatement(sql: "SELECT COUNT(*) FROM player WHERE score > ?")
let moreThanTwentyCount = try Int.fetchOne(statement, arguments: [20])!
let moreThanThirtyCount = try Int.fetchOne(statement, arguments: [30])!
@@ -1051,7 +1051,7 @@
@@ -1076,12 +1076,12 @@
Declaration
Swift
- public var columnCount: Int { get }
+ public var columnCount: Int { get }
@@ -1111,7 +1111,7 @@
@@ -1142,7 +1142,7 @@ case-insensitive way.
@@ -1152,7 +1152,7 @@ case-insensitive way.
diff --git a/docs/4.2/Classes/Statement.html b/docs/4.2/Classes/Statement.html
index 2047297ac..d04e136f8 100644
--- a/docs/4.2/Classes/Statement.html
+++ b/docs/4.2/Classes/Statement.html
@@ -14,7 +14,7 @@
- GRDB 4.2.0 Docs (90% documented)
+ GRDB 4.2.1 Docs (90% documented)
@@ -1046,7 +1046,7 @@ and SelectStatement that fetches rows.
@@ -1071,12 +1071,12 @@ and SelectStatement that fetches rows.
Declaration
Swift
- public var sql: String { get }
+ public var sql: String { get }
@@ -1112,12 +1112,12 @@ and SelectStatement that fetches rows.
Declaration
Swift
- public var arguments: StatementArguments { get set }
+ public var arguments: StatementArguments { get set }
@@ -1148,7 +1148,7 @@ statement arguments.
@@ -1178,7 +1178,7 @@ statement arguments.
@@ -1188,7 +1188,7 @@ statement arguments.
diff --git a/docs/4.2/Classes/TableAlias.html b/docs/4.2/Classes/TableAlias.html
index e83aa1274..22e7b2868 100644
--- a/docs/4.2/Classes/TableAlias.html
+++ b/docs/4.2/Classes/TableAlias.html
@@ -14,7 +14,7 @@
- GRDB 4.2.0 Docs (90% documented)
+ GRDB 4.2.1 Docs (90% documented)
@@ -1045,7 +1045,7 @@
@@ -1071,12 +1071,12 @@ joined queries.
Declaration
Swift
- public subscript(selectable: SQLSelectable) -> SQLSelectable { get }
+ public subscript(selectable: SQLSelectable) -> SQLSelectable { get }
@@ -1102,12 +1102,12 @@ joined queries.
Declaration
Swift
- public subscript(expression: SQLExpression) -> SQLExpression { get }
+ public subscript(expression: SQLExpression) -> SQLExpression { get }
@@ -1117,7 +1117,7 @@ joined queries.
diff --git a/docs/4.2/Classes/TableAlteration.html b/docs/4.2/Classes/TableAlteration.html
index 9d6a663e4..dc918bfcd 100644
--- a/docs/4.2/Classes/TableAlteration.html
+++ b/docs/4.2/Classes/TableAlteration.html
@@ -14,7 +14,7 @@
- GRDB 4.2.0 Docs (90% documented)
+ GRDB 4.2.1 Docs (90% documented)
@@ -1095,7 +1095,7 @@
column definition.
@@ -1105,7 +1105,7 @@ column definition.
diff --git a/docs/4.2/Classes/TableDefinition.html b/docs/4.2/Classes/TableDefinition.html
index 224977311..4db43b1f0 100644
--- a/docs/4.2/Classes/TableDefinition.html
+++ b/docs/4.2/Classes/TableDefinition.html
@@ -14,7 +14,7 @@
- GRDB 4.2.0 Docs (90% documented)
+ GRDB 4.2.1 Docs (90% documented)
@@ -1102,7 +1102,7 @@ inserted in between.
Self so that you can further refine the column definition.
@@ -1175,7 +1175,7 @@ inserted in between.
column definition.
@@ -1246,7 +1246,7 @@ column definition.
@@ -1316,7 +1316,7 @@ column definition.
@@ -1443,7 +1443,7 @@ See https://www.sq
@@ -1465,8 +1465,8 @@ See https://www.sq
try db.create(table: "player") { t in
t.column("personalPhone", .text)
t.column("workPhone", .text)
- let personalPhone = Column("personalPhone")
- let workPhone = Column("workPhone")
+ let personalPhone = Column("personalPhone")
+ let workPhone = Column("workPhone")
t.check(personalPhone != nil || workPhone != nil)
}
@@ -1502,7 +1502,7 @@ See https://www.sq
@@ -1559,7 +1559,7 @@ See https://www.sq
@@ -1569,7 +1569,7 @@ See https://www.sq
diff --git a/docs/4.2/Classes/UpdateStatement.html b/docs/4.2/Classes/UpdateStatement.html
index 08033642c..c92626fd2 100644
--- a/docs/4.2/Classes/UpdateStatement.html
+++ b/docs/4.2/Classes/UpdateStatement.html
@@ -14,7 +14,7 @@
- GRDB 4.2.0 Docs (90% documented)
+ GRDB 4.2.1 Docs (90% documented)
@@ -1015,7 +1015,7 @@
A subclass of Statement that executes SQL queries.
You create UpdateStatement with the Database.makeUpdateStatement() method:
-try dbQueue.inTransaction { db in
+try dbQueue.inTransaction { db in
let statement = try db.makeUpdateStatement(sql: "INSERT INTO player (name) VALUES (?)")
try statement.execute(arguments: ["Arthur"])
try statement.execute(arguments: ["Barbara"])
@@ -1076,7 +1076,7 @@
@@ -1086,7 +1086,7 @@
diff --git a/docs/4.2/Enums.html b/docs/4.2/Enums.html
index 73655b5db..9f159cae2 100644
--- a/docs/4.2/Enums.html
+++ b/docs/4.2/Enums.html
@@ -14,7 +14,7 @@
- GRDB 4.2.0 Docs (90% documented)
+ GRDB 4.2.1 Docs (90% documented)
@@ -1046,7 +1046,7 @@ more information.
@@ -1088,7 +1088,7 @@ more information.
@@ -1121,7 +1121,7 @@ more information.
adopt the standard Encodable protocol encode their date properties.
For example:
-struct Player: EncodableRecord, Encodable {
+struct Player: EncodableRecord, Encodable {
static let databaseDateEncodingStrategy: DatabaseDateEncodingStrategy = .timeIntervalSince1970
var name: String
@@ -1140,7 +1140,7 @@ adopt the standard Encodable protocol encode their date properties.
@@ -1173,7 +1173,7 @@ adopt the standard Encodable protocol encode their date properties.
adopt the standard Encodable protocol encode their UUID properties.
For example:
-struct Player: EncodableProtocol, Encodable {
+struct Player: EncodableProtocol, Encodable {
static let databaseUUIDEncodingStrategy: DatabaseUUIDEncodingStrategy = .string
// encoded in a string like "E621E1F8-C36C-495A-93FC-0C247A3E6E5F"
@@ -1192,7 +1192,7 @@ adopt the standard Encodable protocol encode their UUID properties.
@@ -1225,7 +1225,7 @@ adopt the standard Encodable protocol encode their UUID properties.
adopt the standard Decodable protocol decode their date properties.
For example:
-struct Player: FetchableRecord, Decodable {
+struct Player: FetchableRecord, Decodable {
static let databaseDateDecodingStrategy: DatabaseDateDecodingStrategy = .timeIntervalSince1970
var name: String
@@ -1244,7 +1244,7 @@ adopt the standard Decodable protocol decode their date properties.
@@ -1289,7 +1289,7 @@ column names, and values the old values that have been changed.
@@ -1324,7 +1324,7 @@ column names, and values the old values that have been changed.
@@ -1367,7 +1367,7 @@ of fresh values to your application.
@@ -1402,7 +1402,7 @@ of fresh values to your application.
@@ -1412,7 +1412,7 @@ of fresh values to your application.
diff --git a/docs/4.2/Enums/DatabaseDateDecodingStrategy.html b/docs/4.2/Enums/DatabaseDateDecodingStrategy.html
index 558a6e95f..4a639af65 100644
--- a/docs/4.2/Enums/DatabaseDateDecodingStrategy.html
+++ b/docs/4.2/Enums/DatabaseDateDecodingStrategy.html
@@ -14,7 +14,7 @@
- GRDB 4.2.0 Docs (90% documented)
+ GRDB 4.2.1 Docs (90% documented)
@@ -1016,7 +1016,7 @@
adopt the standard Decodable protocol decode their date properties.
For example:
-struct Player: FetchableRecord, Decodable {
+struct Player: FetchableRecord, Decodable {
static let databaseDateDecodingStrategy: DatabaseDateDecodingStrategy = .timeIntervalSince1970
var name: String
@@ -1069,7 +1069,7 @@ Missing components are assumed to be zero:
@@ -1100,7 +1100,7 @@ midnight UTC on 1 January 2001
@@ -1131,7 +1131,7 @@ midnight UTC on 1 January 1970
@@ -1162,7 +1162,7 @@ midnight UTC on 1 January 1970
@@ -1192,7 +1192,7 @@ midnight UTC on 1 January 1970
@@ -1222,7 +1222,7 @@ midnight UTC on 1 January 1970
@@ -1256,7 +1256,7 @@ error, and react accordingly).
@@ -1266,7 +1266,7 @@ error, and react accordingly).
diff --git a/docs/4.2/Enums/DatabaseDateEncodingStrategy.html b/docs/4.2/Enums/DatabaseDateEncodingStrategy.html
index 19759f158..d65243de7 100644
--- a/docs/4.2/Enums/DatabaseDateEncodingStrategy.html
+++ b/docs/4.2/Enums/DatabaseDateEncodingStrategy.html
@@ -14,7 +14,7 @@
- GRDB 4.2.0 Docs (90% documented)
+ GRDB 4.2.1 Docs (90% documented)
@@ -1016,7 +1016,7 @@
adopt the standard Encodable protocol encode their date properties.
For example:
-struct Player: EncodableRecord, Encodable {
+struct Player: EncodableRecord, Encodable {
static let databaseDateEncodingStrategy: DatabaseDateEncodingStrategy = .timeIntervalSince1970
var name: String
@@ -1056,7 +1056,7 @@ UTC time zone.
@@ -1087,7 +1087,7 @@ midnight UTC on 1 January 2001
@@ -1118,7 +1118,7 @@ midnight UTC on 1 January 1970
@@ -1149,7 +1149,7 @@ midnight UTC on 1 January 1970
@@ -1180,7 +1180,7 @@ midnight UTC on 1 January 1970
@@ -1210,7 +1210,7 @@ midnight UTC on 1 January 1970
@@ -1240,7 +1240,7 @@ midnight UTC on 1 January 1970
@@ -1270,7 +1270,7 @@ midnight UTC on 1 January 1970
@@ -1280,7 +1280,7 @@ midnight UTC on 1 January 1970
diff --git a/docs/4.2/Enums/DatabaseEventKind.html b/docs/4.2/Enums/DatabaseEventKind.html
index 1bc6b9c54..ec105017f 100644
--- a/docs/4.2/Enums/DatabaseEventKind.html
+++ b/docs/4.2/Enums/DatabaseEventKind.html
@@ -14,7 +14,7 @@
- GRDB 4.2.0 Docs (90% documented)
+ GRDB 4.2.1 Docs (90% documented)
@@ -1044,7 +1044,7 @@ more information.
@@ -1074,7 +1074,7 @@ more information.
@@ -1104,7 +1104,7 @@ more information.
@@ -1140,12 +1140,12 @@ more information.
Declaration
Swift
- public var tableName: String { get }
+ public var tableName: String { get }
@@ -1155,7 +1155,7 @@ more information.
diff --git a/docs/4.2/Enums/DatabaseUUIDEncodingStrategy.html b/docs/4.2/Enums/DatabaseUUIDEncodingStrategy.html
index 5fcb34c52..971aafb78 100644
--- a/docs/4.2/Enums/DatabaseUUIDEncodingStrategy.html
+++ b/docs/4.2/Enums/DatabaseUUIDEncodingStrategy.html
@@ -14,7 +14,7 @@
- GRDB 4.2.0 Docs (90% documented)
+ GRDB 4.2.1 Docs (90% documented)
@@ -1016,7 +1016,7 @@
adopt the standard Encodable protocol encode their UUID properties.
For example:
-struct Player: EncodableProtocol, Encodable {
+struct Player: EncodableProtocol, Encodable {
static let databaseUUIDEncodingStrategy: DatabaseUUIDEncodingStrategy = .string
// encoded in a string like "E621E1F8-C36C-495A-93FC-0C247A3E6E5F"
@@ -1055,7 +1055,7 @@ adopt the standard Encodable protocol encode their UUID properties.
@@ -1085,7 +1085,7 @@ adopt the standard Encodable protocol encode their UUID properties.
@@ -1095,7 +1095,7 @@ adopt the standard Encodable protocol encode their UUID properties.
diff --git a/docs/4.2/Enums/FetchedRecordChange.html b/docs/4.2/Enums/FetchedRecordChange.html
index b063f0a75..ead3295ae 100644
--- a/docs/4.2/Enums/FetchedRecordChange.html
+++ b/docs/4.2/Enums/FetchedRecordChange.html
@@ -14,7 +14,7 @@
- GRDB 4.2.0 Docs (90% documented)
+ GRDB 4.2.1 Docs (90% documented)
@@ -1046,7 +1046,7 @@ column names, and values the old values that have been changed.
@@ -1076,7 +1076,7 @@ column names, and values the old values that have been changed.
@@ -1108,7 +1108,7 @@ have been changed.
@@ -1140,7 +1140,7 @@ been changed.
@@ -1175,12 +1175,12 @@ been changed.
Declaration
Swift
- public var description: String { get }
+ public var description: String { get }
@@ -1190,7 +1190,7 @@ been changed.
diff --git a/docs/4.2/Enums/PersistenceError.html b/docs/4.2/Enums/PersistenceError.html
index b78a273d9..b74fe24ce 100644
--- a/docs/4.2/Enums/PersistenceError.html
+++ b/docs/4.2/Enums/PersistenceError.html
@@ -14,7 +14,7 @@
- GRDB 4.2.0 Docs (90% documented)
+ GRDB 4.2.1 Docs (90% documented)
@@ -1049,7 +1049,7 @@ found in the database.
@@ -1059,7 +1059,7 @@ found in the database.
diff --git a/docs/4.2/Enums/SQLLogicalBinaryOperator.html b/docs/4.2/Enums/SQLLogicalBinaryOperator.html
index ede296b87..b7cfaae3e 100644
--- a/docs/4.2/Enums/SQLLogicalBinaryOperator.html
+++ b/docs/4.2/Enums/SQLLogicalBinaryOperator.html
@@ -14,7 +14,7 @@
- GRDB 4.2.0 Docs (90% documented)
+ GRDB 4.2.1 Docs (90% documented)
@@ -1043,7 +1043,7 @@
@@ -1073,7 +1073,7 @@
@@ -1083,7 +1083,7 @@
diff --git a/docs/4.2/Enums/ValueReducers.html b/docs/4.2/Enums/ValueReducers.html
index fedb16f5f..712e6698e 100644
--- a/docs/4.2/Enums/ValueReducers.html
+++ b/docs/4.2/Enums/ValueReducers.html
@@ -14,7 +14,7 @@
- GRDB 4.2.0 Docs (90% documented)
+ GRDB 4.2.1 Docs (90% documented)
@@ -1053,7 +1053,7 @@
@@ -1098,7 +1098,7 @@
@@ -1144,7 +1144,7 @@
@@ -1191,7 +1191,7 @@
@@ -1239,7 +1239,7 @@
@@ -1288,7 +1288,7 @@
@@ -1338,7 +1338,7 @@
@@ -1348,7 +1348,7 @@
diff --git a/docs/4.2/Enums/ValueReducers/Combine2.html b/docs/4.2/Enums/ValueReducers/Combine2.html
index cac37a60f..cc3c11c32 100644
--- a/docs/4.2/Enums/ValueReducers/Combine2.html
+++ b/docs/4.2/Enums/ValueReducers/Combine2.html
@@ -14,7 +14,7 @@
- GRDB 4.2.0 Docs (90% documented)
+ GRDB 4.2.1 Docs (90% documented)
@@ -1044,7 +1044,7 @@
@@ -1073,7 +1073,7 @@
@@ -1102,7 +1102,7 @@
@@ -1131,7 +1131,7 @@
@@ -1141,7 +1141,7 @@
diff --git a/docs/4.2/Enums/ValueReducers/Combine3.html b/docs/4.2/Enums/ValueReducers/Combine3.html
index 56fd71c98..8f206f6fb 100644
--- a/docs/4.2/Enums/ValueReducers/Combine3.html
+++ b/docs/4.2/Enums/ValueReducers/Combine3.html
@@ -14,7 +14,7 @@
- GRDB 4.2.0 Docs (90% documented)
+ GRDB 4.2.1 Docs (90% documented)
@@ -1045,7 +1045,7 @@
@@ -1074,7 +1074,7 @@
@@ -1103,7 +1103,7 @@
@@ -1132,7 +1132,7 @@
@@ -1142,7 +1142,7 @@
diff --git a/docs/4.2/Enums/ValueReducers/Combine4.html b/docs/4.2/Enums/ValueReducers/Combine4.html
index 8b1fc2d36..a25b3ca42 100644
--- a/docs/4.2/Enums/ValueReducers/Combine4.html
+++ b/docs/4.2/Enums/ValueReducers/Combine4.html
@@ -14,7 +14,7 @@
- GRDB 4.2.0 Docs (90% documented)
+ GRDB 4.2.1 Docs (90% documented)
@@ -1046,7 +1046,7 @@
@@ -1075,7 +1075,7 @@
@@ -1104,7 +1104,7 @@
@@ -1133,7 +1133,7 @@
@@ -1143,7 +1143,7 @@
diff --git a/docs/4.2/Enums/ValueReducers/Combine5.html b/docs/4.2/Enums/ValueReducers/Combine5.html
index 09218c800..7ce895040 100644
--- a/docs/4.2/Enums/ValueReducers/Combine5.html
+++ b/docs/4.2/Enums/ValueReducers/Combine5.html
@@ -14,7 +14,7 @@
- GRDB 4.2.0 Docs (90% documented)
+ GRDB 4.2.1 Docs (90% documented)
@@ -1047,7 +1047,7 @@
@@ -1076,7 +1076,7 @@
@@ -1105,7 +1105,7 @@
@@ -1134,7 +1134,7 @@
@@ -1144,7 +1144,7 @@
diff --git a/docs/4.2/Enums/ValueReducers/Combine6.html b/docs/4.2/Enums/ValueReducers/Combine6.html
index 33e47a54a..e21ff061b 100644
--- a/docs/4.2/Enums/ValueReducers/Combine6.html
+++ b/docs/4.2/Enums/ValueReducers/Combine6.html
@@ -14,7 +14,7 @@
- GRDB 4.2.0 Docs (90% documented)
+ GRDB 4.2.1 Docs (90% documented)
@@ -1048,7 +1048,7 @@
@@ -1077,7 +1077,7 @@
@@ -1106,7 +1106,7 @@
@@ -1135,7 +1135,7 @@
@@ -1145,7 +1145,7 @@
diff --git a/docs/4.2/Enums/ValueReducers/Combine7.html b/docs/4.2/Enums/ValueReducers/Combine7.html
index 8287d6efb..8b8226470 100644
--- a/docs/4.2/Enums/ValueReducers/Combine7.html
+++ b/docs/4.2/Enums/ValueReducers/Combine7.html
@@ -14,7 +14,7 @@
- GRDB 4.2.0 Docs (90% documented)
+ GRDB 4.2.1 Docs (90% documented)
@@ -1049,7 +1049,7 @@
@@ -1078,7 +1078,7 @@
@@ -1107,7 +1107,7 @@
@@ -1136,7 +1136,7 @@
@@ -1146,7 +1146,7 @@
diff --git a/docs/4.2/Enums/ValueReducers/Combine8.html b/docs/4.2/Enums/ValueReducers/Combine8.html
index b4d790f6d..0182f3dc7 100644
--- a/docs/4.2/Enums/ValueReducers/Combine8.html
+++ b/docs/4.2/Enums/ValueReducers/Combine8.html
@@ -14,7 +14,7 @@
- GRDB 4.2.0 Docs (90% documented)
+ GRDB 4.2.1 Docs (90% documented)
@@ -1050,7 +1050,7 @@
@@ -1079,7 +1079,7 @@
@@ -1108,7 +1108,7 @@
@@ -1137,7 +1137,7 @@
@@ -1147,7 +1147,7 @@
diff --git a/docs/4.2/Enums/ValueScheduling.html b/docs/4.2/Enums/ValueScheduling.html
index 89b296328..a1357c098 100644
--- a/docs/4.2/Enums/ValueScheduling.html
+++ b/docs/4.2/Enums/ValueScheduling.html
@@ -14,7 +14,7 @@
- GRDB 4.2.0 Docs (90% documented)
+ GRDB 4.2.1 Docs (90% documented)
@@ -1057,8 +1057,8 @@ is also notified on the main queue, but asynchronously:
When the database changes, fresh values are asynchronously notified on
the main queue:
// Eventually prints "fresh players" on the main queue
-try dbQueue.write { db in
- try Player(...).insert(db)
+try dbQueue.write { db in
+ try Player(...).insert(db)
}
@@ -1072,7 +1072,7 @@ the main queue:
@@ -1105,7 +1105,7 @@ is true.
@@ -1150,7 +1150,7 @@ unspecified queues.
@@ -1160,7 +1160,7 @@ unspecified queues.
diff --git a/docs/4.2/Extensions.html b/docs/4.2/Extensions.html
index 0c500ab7c..93fbb7d90 100644
--- a/docs/4.2/Extensions.html
+++ b/docs/4.2/Extensions.html
@@ -14,7 +14,7 @@
- GRDB 4.2.0 Docs (90% documented)
+ GRDB 4.2.1 Docs (90% documented)
@@ -2101,7 +2101,7 @@ and arrays of optional DatabaseValueConvertible:
@@ -2184,7 +2184,7 @@ and arrays of optional DatabaseValueConvertible:
@@ -2313,7 +2313,7 @@ and arrays of optional DatabaseValueConvertible:
diff --git a/docs/4.2/Extensions/Array.html b/docs/4.2/Extensions/Array.html
index 6e5572f09..82e781075 100644
--- a/docs/4.2/Extensions/Array.html
+++ b/docs/4.2/Extensions/Array.html
@@ -14,7 +14,7 @@
- GRDB 4.2.0 Docs (90% documented)
+ GRDB 4.2.1 Docs (90% documented)
@@ -1032,7 +1032,7 @@
Creates an array containing the elements of a cursor.
let cursor = try String.fetchCursor(db, sql: "SELECT 'foo' UNION ALL SELECT 'bar'")
-let strings = try Array(cursor) // ["foo", "bar"]
+let strings = try Array(cursor) // ["foo", "bar"]
@@ -1046,7 +1046,7 @@
@@ -1056,7 +1056,7 @@
diff --git a/docs/4.2/Extensions/Bool.html b/docs/4.2/Extensions/Bool.html
index 5972ad36a..3056f4e5d 100644
--- a/docs/4.2/Extensions/Bool.html
+++ b/docs/4.2/Extensions/Bool.html
@@ -14,7 +14,7 @@
- GRDB 4.2.0 Docs (90% documented)
+ GRDB 4.2.1 Docs (90% documented)
@@ -1075,7 +1075,7 @@
@@ -1100,12 +1100,12 @@
Declaration
Swift
- public var databaseValue: DatabaseValue { get }
+ public var databaseValue: DatabaseValue { get }
@@ -1135,7 +1135,7 @@
@@ -1145,7 +1145,7 @@
diff --git a/docs/4.2/Extensions/CGFloat.html b/docs/4.2/Extensions/CGFloat.html
index fc0509f1e..9141cc1b2 100644
--- a/docs/4.2/Extensions/CGFloat.html
+++ b/docs/4.2/Extensions/CGFloat.html
@@ -14,7 +14,7 @@
- GRDB 4.2.0 Docs (90% documented)
+ GRDB 4.2.1 Docs (90% documented)
@@ -1038,12 +1038,12 @@
Declaration
Swift
- public var databaseValue: DatabaseValue { get }
+ public var databaseValue: DatabaseValue { get }
@@ -1073,7 +1073,7 @@
@@ -1083,7 +1083,7 @@
diff --git a/docs/4.2/Extensions/ClosedRange.html b/docs/4.2/Extensions/ClosedRange.html
index e170536ff..3875dcc22 100644
--- a/docs/4.2/Extensions/ClosedRange.html
+++ b/docs/4.2/Extensions/ClosedRange.html
@@ -14,7 +14,7 @@
- GRDB 4.2.0 Docs (90% documented)
+ GRDB 4.2.1 Docs (90% documented)
@@ -1032,7 +1032,7 @@
An SQL expression that checks the inclusion of an expression in a range.
// email BETWEEN 'A' AND 'B'
-("A"..."B").contains(Column("email"))
+("A"..."B").contains(Column("email"))
@@ -1045,7 +1045,7 @@
@@ -1065,7 +1065,7 @@
An SQL expression that checks the inclusion of an expression in a range.
// email BETWEEN 'A' AND 'B' COLLATE NOCASE
-("A"..."B").contains(Column("email").collating(.nocase))
+("A"..."B").contains(Column("email").collating(.nocase))
@@ -1078,7 +1078,7 @@
@@ -1088,7 +1088,7 @@
diff --git a/docs/4.2/Extensions/Collection.html b/docs/4.2/Extensions/Collection.html
index 82c2dafd0..85e75db2f 100644
--- a/docs/4.2/Extensions/Collection.html
+++ b/docs/4.2/Extensions/Collection.html
@@ -14,7 +14,7 @@
- GRDB 4.2.0 Docs (90% documented)
+ GRDB 4.2.1 Docs (90% documented)
@@ -1050,7 +1050,7 @@ inserting the given separator between each element.
@@ -1060,7 +1060,7 @@ inserting the given separator between each element.
diff --git a/docs/4.2/Extensions/Column.html b/docs/4.2/Extensions/Column.html
index c170181ce..b16bfea83 100644
--- a/docs/4.2/Extensions/Column.html
+++ b/docs/4.2/Extensions/Column.html
@@ -14,7 +14,7 @@
- GRDB 4.2.0 Docs (90% documented)
+ GRDB 4.2.1 Docs (90% documented)
@@ -1035,7 +1035,7 @@
diff --git a/docs/4.2/Extensions/CountableClosedRange.html b/docs/4.2/Extensions/CountableClosedRange.html
index 79affd05a..d4e809d37 100644
--- a/docs/4.2/Extensions/CountableClosedRange.html
+++ b/docs/4.2/Extensions/CountableClosedRange.html
@@ -14,7 +14,7 @@
- GRDB 4.2.0 Docs (90% documented)
+ GRDB 4.2.1 Docs (90% documented)
@@ -1032,7 +1032,7 @@
An SQL expression that checks the inclusion of an expression in a range.
// id BETWEEN 1 AND 10
-(1...10).contains(Column("id"))
+(1...10).contains(Column("id"))
@@ -1045,7 +1045,7 @@
@@ -1055,7 +1055,7 @@
diff --git a/docs/4.2/Extensions/CountableRange.html b/docs/4.2/Extensions/CountableRange.html
index e13c4329d..532c74cdd 100644
--- a/docs/4.2/Extensions/CountableRange.html
+++ b/docs/4.2/Extensions/CountableRange.html
@@ -14,7 +14,7 @@
- GRDB 4.2.0 Docs (90% documented)
+ GRDB 4.2.1 Docs (90% documented)
@@ -1032,7 +1032,7 @@
An SQL expression that checks the inclusion of an expression in a range.
// id BETWEEN 1 AND 9
-(1..<10).contains(Column("id"))
+(1..<10).contains(Column("id"))
@@ -1045,7 +1045,7 @@
@@ -1055,7 +1055,7 @@
diff --git a/docs/4.2/Extensions/Data.html b/docs/4.2/Extensions/Data.html
index 5fb0a72f9..33383c0e0 100644
--- a/docs/4.2/Extensions/Data.html
+++ b/docs/4.2/Extensions/Data.html
@@ -14,7 +14,7 @@
- GRDB 4.2.0 Docs (90% documented)
+ GRDB 4.2.1 Docs (90% documented)
@@ -1043,7 +1043,7 @@
@@ -1068,12 +1068,12 @@
Declaration
Swift
- public var databaseValue: DatabaseValue { get }
+ public var databaseValue: DatabaseValue { get }
@@ -1104,7 +1104,7 @@ a Blob.
@@ -1114,7 +1114,7 @@ a Blob.
diff --git a/docs/4.2/Extensions/Database.html b/docs/4.2/Extensions/Database.html
index b315b3193..e759de241 100644
--- a/docs/4.2/Extensions/Database.html
+++ b/docs/4.2/Extensions/Database.html
@@ -14,7 +14,7 @@
- GRDB 4.2.0 Docs (90% documented)
+ GRDB 4.2.1 Docs (90% documented)
@@ -1055,7 +1055,7 @@
Add a custom FTS5 tokenizer.
-class MyTokenizer : FTS5CustomTokenizer { ... }
+class MyTokenizer : FTS5CustomTokenizer { ... }
db.add(tokenizer: MyTokenizer.self)
@@ -1131,10 +1131,10 @@ invalid syntax.
database queue, or after the database has been closed.
Use this method when you implement a custom wrapper tokenizer:
-final class MyTokenizer : FTS5WrapperTokenizer {
+final class MyTokenizer : FTS5WrapperTokenizer {
var wrappedTokenizer: FTS5Tokenizer
- init(db: Database, arguments: [String]) throws {
+ init(db: Database, arguments: [String]) throws {
wrappedTokenizer = try db.makeTokenizer(.unicode61())
}
}
@@ -1149,7 +1149,7 @@ database queue, or after the database has been closed.
diff --git a/docs/4.2/Extensions/DatabasePool.html b/docs/4.2/Extensions/DatabasePool.html
index bc071f8d5..a2e64350a 100644
--- a/docs/4.2/Extensions/DatabasePool.html
+++ b/docs/4.2/Extensions/DatabasePool.html
@@ -14,7 +14,7 @@
- GRDB 4.2.0 Docs (90% documented)
+ GRDB 4.2.1 Docs (90% documented)
@@ -1042,7 +1042,7 @@
diff --git a/docs/4.2/Extensions/DatabaseQueue.html b/docs/4.2/Extensions/DatabaseQueue.html
index a25134b22..727d8b373 100644
--- a/docs/4.2/Extensions/DatabaseQueue.html
+++ b/docs/4.2/Extensions/DatabaseQueue.html
@@ -14,7 +14,7 @@
- GRDB 4.2.0 Docs (90% documented)
+ GRDB 4.2.1 Docs (90% documented)
@@ -1062,7 +1062,7 @@
Add a custom FTS5 tokenizer.
-class MyTokenizer : FTS5CustomTokenizer { ... }
+class MyTokenizer : FTS5CustomTokenizer { ... }
dbQueue.add(tokenizer: MyTokenizer.self)
@@ -1075,7 +1075,7 @@
diff --git a/docs/4.2/Extensions/Date.html b/docs/4.2/Extensions/Date.html
index b4364a687..9a70ba120 100644
--- a/docs/4.2/Extensions/Date.html
+++ b/docs/4.2/Extensions/Date.html
@@ -14,7 +14,7 @@
- GRDB 4.2.0 Docs (90% documented)
+ GRDB 4.2.1 Docs (90% documented)
@@ -1040,12 +1040,12 @@
Declaration
Swift
- public var databaseValue: DatabaseValue { get }
+ public var databaseValue: DatabaseValue { get }
@@ -1084,7 +1084,7 @@ are set to zero if missing.
@@ -1114,7 +1114,7 @@ are set to zero if missing.
@@ -1180,7 +1180,7 @@ are set to zero if missing.
@@ -1190,7 +1190,7 @@ are set to zero if missing.
diff --git a/docs/4.2/Extensions/Double.html b/docs/4.2/Extensions/Double.html
index 07132064e..abbb5e277 100644
--- a/docs/4.2/Extensions/Double.html
+++ b/docs/4.2/Extensions/Double.html
@@ -14,7 +14,7 @@
- GRDB 4.2.0 Docs (90% documented)
+ GRDB 4.2.1 Docs (90% documented)
@@ -1075,7 +1075,7 @@
@@ -1100,12 +1100,12 @@
Declaration
Swift
- public var databaseValue: DatabaseValue { get }
+ public var databaseValue: DatabaseValue { get }
@@ -1135,7 +1135,7 @@
@@ -1145,7 +1145,7 @@
diff --git a/docs/4.2/Extensions/Float.html b/docs/4.2/Extensions/Float.html
index 31adf63d0..31b79ec9d 100644
--- a/docs/4.2/Extensions/Float.html
+++ b/docs/4.2/Extensions/Float.html
@@ -14,7 +14,7 @@
- GRDB 4.2.0 Docs (90% documented)
+ GRDB 4.2.1 Docs (90% documented)
@@ -1075,7 +1075,7 @@
@@ -1100,12 +1100,12 @@
Declaration
Swift
- public var databaseValue: DatabaseValue { get }
+ public var databaseValue: DatabaseValue { get }
@@ -1135,7 +1135,7 @@
@@ -1145,7 +1145,7 @@
diff --git a/docs/4.2/Extensions/Int.html b/docs/4.2/Extensions/Int.html
index 99f823be0..285670456 100644
--- a/docs/4.2/Extensions/Int.html
+++ b/docs/4.2/Extensions/Int.html
@@ -14,7 +14,7 @@
- GRDB 4.2.0 Docs (90% documented)
+ GRDB 4.2.1 Docs (90% documented)
@@ -1075,7 +1075,7 @@
@@ -1100,12 +1100,12 @@
Declaration
Swift
- public var databaseValue: DatabaseValue { get }
+ public var databaseValue: DatabaseValue { get }
@@ -1135,7 +1135,7 @@
@@ -1145,7 +1145,7 @@
diff --git a/docs/4.2/Extensions/Int16.html b/docs/4.2/Extensions/Int16.html
index ea97eb695..9617ce283 100644
--- a/docs/4.2/Extensions/Int16.html
+++ b/docs/4.2/Extensions/Int16.html
@@ -14,7 +14,7 @@
- GRDB 4.2.0 Docs (90% documented)
+ GRDB 4.2.1 Docs (90% documented)
@@ -1075,7 +1075,7 @@
@@ -1100,12 +1100,12 @@
Declaration
Swift
- public var databaseValue: DatabaseValue { get }
+ public var databaseValue: DatabaseValue { get }
@@ -1135,7 +1135,7 @@
@@ -1145,7 +1145,7 @@
diff --git a/docs/4.2/Extensions/Int32.html b/docs/4.2/Extensions/Int32.html
index fd7a7d6f3..c42cce797 100644
--- a/docs/4.2/Extensions/Int32.html
+++ b/docs/4.2/Extensions/Int32.html
@@ -14,7 +14,7 @@
- GRDB 4.2.0 Docs (90% documented)
+ GRDB 4.2.1 Docs (90% documented)
@@ -1075,7 +1075,7 @@
@@ -1100,12 +1100,12 @@
Declaration
Swift
- public var databaseValue: DatabaseValue { get }
+ public var databaseValue: DatabaseValue { get }
@@ -1135,7 +1135,7 @@
@@ -1145,7 +1145,7 @@
diff --git a/docs/4.2/Extensions/Int64.html b/docs/4.2/Extensions/Int64.html
index 00e6a3b8a..4a68dd3fd 100644
--- a/docs/4.2/Extensions/Int64.html
+++ b/docs/4.2/Extensions/Int64.html
@@ -14,7 +14,7 @@
- GRDB 4.2.0 Docs (90% documented)
+ GRDB 4.2.1 Docs (90% documented)
@@ -1075,7 +1075,7 @@
@@ -1100,12 +1100,12 @@
Declaration
Swift
- public var databaseValue: DatabaseValue { get }
+ public var databaseValue: DatabaseValue { get }
@@ -1135,7 +1135,7 @@
@@ -1145,7 +1145,7 @@
diff --git a/docs/4.2/Extensions/Int8.html b/docs/4.2/Extensions/Int8.html
index b8891bc57..b0aafc2a5 100644
--- a/docs/4.2/Extensions/Int8.html
+++ b/docs/4.2/Extensions/Int8.html
@@ -14,7 +14,7 @@
- GRDB 4.2.0 Docs (90% documented)
+ GRDB 4.2.1 Docs (90% documented)
@@ -1075,7 +1075,7 @@
@@ -1100,12 +1100,12 @@
Declaration
Swift
- public var databaseValue: DatabaseValue { get }
+ public var databaseValue: DatabaseValue { get }
@@ -1135,7 +1135,7 @@
@@ -1145,7 +1145,7 @@
diff --git a/docs/4.2/Extensions/JoinableRequest.html b/docs/4.2/Extensions/JoinableRequest.html
index 344e37776..23118fb59 100644
--- a/docs/4.2/Extensions/JoinableRequest.html
+++ b/docs/4.2/Extensions/JoinableRequest.html
@@ -14,7 +14,7 @@
- GRDB 4.2.0 Docs (90% documented)
+ GRDB 4.2.1 Docs (90% documented)
@@ -1042,7 +1042,7 @@
@@ -1074,7 +1074,7 @@ require that the associated database table contains a matching row.
@@ -1106,7 +1106,7 @@ that the associated database table contains a matching row.
@@ -1138,7 +1138,7 @@ require that the associated database table contains a matching row.
@@ -1170,7 +1170,7 @@ that the associated database table contains a matching row.
@@ -1180,7 +1180,7 @@ that the associated database table contains a matching row.
diff --git a/docs/4.2/Extensions/NSData.html b/docs/4.2/Extensions/NSData.html
index 9523510c8..d490d5d3f 100644
--- a/docs/4.2/Extensions/NSData.html
+++ b/docs/4.2/Extensions/NSData.html
@@ -14,7 +14,7 @@
- GRDB 4.2.0 Docs (90% documented)
+ GRDB 4.2.1 Docs (90% documented)
@@ -1038,12 +1038,12 @@
Declaration
Swift
- public var databaseValue: DatabaseValue { get }
+ public var databaseValue: DatabaseValue { get }
@@ -1069,12 +1069,12 @@ a Blob.
Declaration
Swift
- public static func fromDatabaseValue(_ dbValue: DatabaseValue) -> `Self`?
+ public static func fromDatabaseValue(_ dbValue: DatabaseValue) -> `Self`?
@@ -1084,7 +1084,7 @@ a Blob.
diff --git a/docs/4.2/Extensions/NSDate.html b/docs/4.2/Extensions/NSDate.html
index 83cd83b16..684bff0d6 100644
--- a/docs/4.2/Extensions/NSDate.html
+++ b/docs/4.2/Extensions/NSDate.html
@@ -14,7 +14,7 @@
- GRDB 4.2.0 Docs (90% documented)
+ GRDB 4.2.1 Docs (90% documented)
@@ -1040,12 +1040,12 @@
Declaration
Swift
- public var databaseValue: DatabaseValue { get }
+ public var databaseValue: DatabaseValue { get }
@@ -1079,12 +1079,12 @@ are set to zero if missing.
Declaration
Swift
- public static func fromDatabaseValue(_ dbValue: DatabaseValue) -> `Self`?
+ public static func fromDatabaseValue(_ dbValue: DatabaseValue) -> `Self`?
@@ -1094,7 +1094,7 @@ are set to zero if missing.
diff --git a/docs/4.2/Extensions/NSNull.html b/docs/4.2/Extensions/NSNull.html
index 7bc755dec..3de238c5e 100644
--- a/docs/4.2/Extensions/NSNull.html
+++ b/docs/4.2/Extensions/NSNull.html
@@ -14,7 +14,7 @@
- GRDB 4.2.0 Docs (90% documented)
+ GRDB 4.2.1 Docs (90% documented)
@@ -1038,12 +1038,12 @@
Declaration
Swift
- public var databaseValue: DatabaseValue { get }
+ public var databaseValue: DatabaseValue { get }
@@ -1068,12 +1068,12 @@
Declaration
Swift
- public static func fromDatabaseValue(_ dbValue: DatabaseValue) -> `Self`?
+ public static func fromDatabaseValue(_ dbValue: DatabaseValue) -> `Self`?
@@ -1083,7 +1083,7 @@
diff --git a/docs/4.2/Extensions/NSNumber.html b/docs/4.2/Extensions/NSNumber.html
index ae2fe289a..7c9c6a846 100644
--- a/docs/4.2/Extensions/NSNumber.html
+++ b/docs/4.2/Extensions/NSNumber.html
@@ -14,7 +14,7 @@
- GRDB 4.2.0 Docs (90% documented)
+ GRDB 4.2.1 Docs (90% documented)
@@ -1038,12 +1038,12 @@
Declaration
Swift
- public var databaseValue: DatabaseValue { get }
+ public var databaseValue: DatabaseValue { get }
@@ -1068,12 +1068,12 @@
Declaration
Swift
- public static func fromDatabaseValue(_ dbValue: DatabaseValue) -> `Self`?
+ public static func fromDatabaseValue(_ dbValue: DatabaseValue) -> `Self`?
@@ -1083,7 +1083,7 @@
diff --git a/docs/4.2/Extensions/NSString.html b/docs/4.2/Extensions/NSString.html
index 86db0fb82..6a0fb66e4 100644
--- a/docs/4.2/Extensions/NSString.html
+++ b/docs/4.2/Extensions/NSString.html
@@ -14,7 +14,7 @@
- GRDB 4.2.0 Docs (90% documented)
+ GRDB 4.2.1 Docs (90% documented)
@@ -1038,12 +1038,12 @@
Declaration
Swift
- public var databaseValue: DatabaseValue { get }
+ public var databaseValue: DatabaseValue { get }
@@ -1068,12 +1068,12 @@
Declaration
Swift
- public static func fromDatabaseValue(_ dbValue: DatabaseValue) -> `Self`?
+ public static func fromDatabaseValue(_ dbValue: DatabaseValue) -> `Self`?
@@ -1083,7 +1083,7 @@
diff --git a/docs/4.2/Extensions/NSURL.html b/docs/4.2/Extensions/NSURL.html
index 30ae0d41b..b4e4cf300 100644
--- a/docs/4.2/Extensions/NSURL.html
+++ b/docs/4.2/Extensions/NSURL.html
@@ -14,7 +14,7 @@
- GRDB 4.2.0 Docs (90% documented)
+ GRDB 4.2.1 Docs (90% documented)
@@ -1039,12 +1039,12 @@
Declaration
Swift
- public var databaseValue: DatabaseValue { get }
+ public var databaseValue: DatabaseValue { get }
@@ -1069,12 +1069,12 @@
Declaration
Swift
- public static func fromDatabaseValue(_ dbValue: DatabaseValue) -> `Self`?
+ public static func fromDatabaseValue(_ dbValue: DatabaseValue) -> `Self`?
@@ -1084,7 +1084,7 @@
diff --git a/docs/4.2/Extensions/NSUUID.html b/docs/4.2/Extensions/NSUUID.html
index d83f576b0..96d68b709 100644
--- a/docs/4.2/Extensions/NSUUID.html
+++ b/docs/4.2/Extensions/NSUUID.html
@@ -14,7 +14,7 @@
- GRDB 4.2.0 Docs (90% documented)
+ GRDB 4.2.1 Docs (90% documented)
@@ -1037,12 +1037,12 @@
Declaration
Swift
- public var databaseValue: DatabaseValue { get }
+ public var databaseValue: DatabaseValue { get }
@@ -1066,12 +1066,12 @@
Declaration
Swift
- public static func fromDatabaseValue(_ dbValue: DatabaseValue) -> `Self`?
+ public static func fromDatabaseValue(_ dbValue: DatabaseValue) -> `Self`?
@@ -1081,7 +1081,7 @@
diff --git a/docs/4.2/Extensions/Optional.html b/docs/4.2/Extensions/Optional.html
index a76f8e827..8d8ef8446 100644
--- a/docs/4.2/Extensions/Optional.html
+++ b/docs/4.2/Extensions/Optional.html
@@ -14,7 +14,7 @@
- GRDB 4.2.0 Docs (90% documented)
+ GRDB 4.2.1 Docs (90% documented)
@@ -1128,7 +1128,7 @@ elements are undefined.
A cursor over fetched optional values.
@@ -1217,7 +1217,7 @@ elements are undefined.
An array of optional values.
@@ -1271,7 +1271,7 @@ elements are undefined.
public static func fetchCursor(
_ db: Database,
sql: String,
- arguments: StatementArguments = StatementArguments(),
+ arguments: StatementArguments = StatementArguments(),
adapter: RowAdapter? = nil)
throws -> NullableDatabaseValueCursor<Wrapped>
@@ -1337,7 +1337,7 @@ elements are undefined.
A cursor over fetched optional values.
@@ -1372,7 +1372,7 @@ elements are undefined.
public static func fetchAll(
_ db: Database,
sql: String,
- arguments: StatementArguments = StatementArguments(),
+ arguments: StatementArguments = StatementArguments(),
adapter: RowAdapter? = nil)
throws -> [Wrapped?]
@@ -1438,7 +1438,7 @@ elements are undefined.
An array of optional values.
@@ -1468,7 +1468,7 @@ elements are undefined.
Returns a cursor over optional values fetched from a fetch request.
-let request = Player.select(Column("name"))
+let request = Player.select(Column("name"))
let names = try Optional<String>.fetchCursor(db, request) // Cursor of String?
while let name = try names.next() { // String?
...
@@ -1531,7 +1531,7 @@ elements are undefined.
A cursor over fetched optional values.
@@ -1550,7 +1550,7 @@ elements are undefined.
Returns an array of optional values fetched from a fetch request.
-let request = Player.select(Column("name"))
+let request = Player.select(Column("name"))
let names = try Optional<String>.fetchAll(db, request) // [String?]
@@ -1604,7 +1604,7 @@ elements are undefined.
An array of optional values.
@@ -1712,7 +1712,7 @@ elements are undefined.
A cursor over fetched optional values.
@@ -1801,7 +1801,7 @@ elements are undefined.
An array of optional values.
@@ -1855,7 +1855,7 @@ elements are undefined.
public static func fetchCursor(
_ db: Database,
sql: String,
- arguments: StatementArguments = StatementArguments(),
+ arguments: StatementArguments = StatementArguments(),
adapter: RowAdapter? = nil)
throws -> FastNullableDatabaseValueCursor<Wrapped>
@@ -1921,7 +1921,7 @@ elements are undefined.
A cursor over fetched optional values.
@@ -1956,7 +1956,7 @@ elements are undefined.
public static func fetchAll(
_ db: Database,
sql: String,
- arguments: StatementArguments = StatementArguments(),
+ arguments: StatementArguments = StatementArguments(),
adapter: RowAdapter? = nil)
throws -> [Wrapped?]
@@ -2022,7 +2022,7 @@ elements are undefined.
An array of optional values.
@@ -2052,7 +2052,7 @@ elements are undefined.
Returns a cursor over optional values fetched from a fetch request.
-let request = Player.select(Column("name"))
+let request = Player.select(Column("name"))
let names = try Optional<String>.fetchCursor(db, request) // Cursor of String?
while let name = try names.next() { // String?
...
@@ -2115,7 +2115,7 @@ elements are undefined.
A cursor over fetched optional values.
@@ -2134,7 +2134,7 @@ elements are undefined.
Returns an array of optional values fetched from a fetch request.
-let request = Player.select(Column("name"))
+let request = Player.select(Column("name"))
let names = try Optional<String>.fetchAll(db, request) // [String?]
@@ -2188,7 +2188,7 @@ elements are undefined.
An array of optional values.
@@ -2198,7 +2198,7 @@ elements are undefined.
diff --git a/docs/4.2/Extensions/Range.html b/docs/4.2/Extensions/Range.html
index fa334c600..a1328862e 100644
--- a/docs/4.2/Extensions/Range.html
+++ b/docs/4.2/Extensions/Range.html
@@ -14,7 +14,7 @@
- GRDB 4.2.0 Docs (90% documented)
+ GRDB 4.2.1 Docs (90% documented)
@@ -1032,7 +1032,7 @@
An SQL expression that checks the inclusion of an expression in a range.
// email >= 'A' AND email < 'B'
-("A"..<"B").contains(Column("email"))
+("A"..<"B").contains(Column("email"))
@@ -1045,7 +1045,7 @@
@@ -1065,7 +1065,7 @@
An SQL expression that checks the inclusion of an expression in a range.
// email >= 'A' COLLATE NOCASE AND email < 'B' COLLATE NOCASE
-("A"..<"B").contains(Column("email").collating(.nocase))
+("A"..<"B").contains(Column("email").collating(.nocase))
@@ -1078,7 +1078,7 @@
@@ -1088,7 +1088,7 @@
diff --git a/docs/4.2/Extensions/SQLLiteral.html b/docs/4.2/Extensions/SQLLiteral.html
index 663f940f1..a11568346 100644
--- a/docs/4.2/Extensions/SQLLiteral.html
+++ b/docs/4.2/Extensions/SQLLiteral.html
@@ -14,7 +14,7 @@
- GRDB 4.2.0 Docs (90% documented)
+ GRDB 4.2.1 Docs (90% documented)
@@ -1035,7 +1035,7 @@
diff --git a/docs/4.2/Extensions/SQLRequest.html b/docs/4.2/Extensions/SQLRequest.html
index 5cac74ce1..f71c64089 100644
--- a/docs/4.2/Extensions/SQLRequest.html
+++ b/docs/4.2/Extensions/SQLRequest.html
@@ -14,7 +14,7 @@
- GRDB 4.2.0 Docs (90% documented)
+ GRDB 4.2.1 Docs (90% documented)
@@ -1035,7 +1035,7 @@
diff --git a/docs/4.2/Extensions/Sequence.html b/docs/4.2/Extensions/Sequence.html
index b9030eb9c..18559ffc4 100644
--- a/docs/4.2/Extensions/Sequence.html
+++ b/docs/4.2/Extensions/Sequence.html
@@ -14,7 +14,7 @@
- GRDB 4.2.0 Docs (90% documented)
+ GRDB 4.2.1 Docs (90% documented)
@@ -1045,7 +1045,7 @@ over self.
@@ -1087,7 +1087,7 @@ inserting the given separator between each element.
@@ -1112,7 +1112,7 @@ inserting the given separator between each element.
An SQL expression that checks the inclusion of an expression in
a sequence.
// id IN (1,2,3)
-[1, 2, 3].contains(Column("id"))
+[1, 2, 3].contains(Column("id"))
@@ -1125,7 +1125,7 @@ a sequence.
@@ -1146,7 +1146,7 @@ a sequence.
An SQL expression that checks the inclusion of an expression in
a sequence.
// name IN ('A', 'B') COLLATE NOCASE
-["A", "B"].contains(Column("name").collating(.nocase))
+["A", "B"].contains(Column("name").collating(.nocase))
@@ -1159,7 +1159,7 @@ a sequence.
@@ -1190,9 +1190,9 @@ logical operator.
// AND (score >= 1000)
// AND (name IS NOT NULL))
let conditions = [
- Column("registered"),
- Column("score") >= 1000,
- Column("name") != nil]
+ Column("registered"),
+ Column("score") >= 1000,
+ Column("name") != nil]
Player.filter(conditions.joined(operator: .and))
@@ -1215,7 +1215,7 @@ and joined(operator: .or) returns false:
@@ -1225,7 +1225,7 @@ and joined(operator: .or) returns false:
diff --git a/docs/4.2/Extensions/Set.html b/docs/4.2/Extensions/Set.html
index b4b200a8f..77e1fbeb0 100644
--- a/docs/4.2/Extensions/Set.html
+++ b/docs/4.2/Extensions/Set.html
@@ -14,7 +14,7 @@
- GRDB 4.2.0 Docs (90% documented)
+ GRDB 4.2.1 Docs (90% documented)
@@ -1032,7 +1032,7 @@
Creates a set containing the elements of a cursor.
let cursor = try String.fetchCursor(db, sql: "SELECT 'foo' UNION ALL SELECT 'foo'")
-let strings = try Set(cursor) // ["foo"]
+let strings = try Set(cursor) // ["foo"]
@@ -1045,7 +1045,7 @@
@@ -1055,7 +1055,7 @@
diff --git a/docs/4.2/Extensions/String.html b/docs/4.2/Extensions/String.html
index 5455a218f..9d04e3b2b 100644
--- a/docs/4.2/Extensions/String.html
+++ b/docs/4.2/Extensions/String.html
@@ -14,7 +14,7 @@
- GRDB 4.2.0 Docs (90% documented)
+ GRDB 4.2.1 Docs (90% documented)
@@ -1075,7 +1075,7 @@
@@ -1100,12 +1100,12 @@
Declaration
Swift
- public var databaseValue: DatabaseValue { get }
+ public var databaseValue: DatabaseValue { get }
@@ -1135,7 +1135,7 @@
@@ -1168,12 +1168,12 @@ SQL query.
Swift
@inlinable
-public var quotedDatabaseIdentifier: String { get }
+public var quotedDatabaseIdentifier: String { get }
@@ -1183,7 +1183,7 @@ SQL query.
diff --git a/docs/4.2/Extensions/TableRecord.html b/docs/4.2/Extensions/TableRecord.html
index afc34cd3f..2d940dae3 100644
--- a/docs/4.2/Extensions/TableRecord.html
+++ b/docs/4.2/Extensions/TableRecord.html
@@ -14,7 +14,7 @@
- GRDB 4.2.0 Docs (90% documented)
+ GRDB 4.2.1 Docs (90% documented)
@@ -1048,7 +1048,7 @@ database row.
diff --git a/docs/4.2/Extensions/TableRequest.html b/docs/4.2/Extensions/TableRequest.html
index f60dde200..03d314059 100644
--- a/docs/4.2/Extensions/TableRequest.html
+++ b/docs/4.2/Extensions/TableRequest.html
@@ -14,7 +14,7 @@
- GRDB 4.2.0 Docs (90% documented)
+ GRDB 4.2.1 Docs (90% documented)
@@ -1054,7 +1054,7 @@ for individual requests with the TableRecord.select method.
diff --git a/docs/4.2/Extensions/UInt.html b/docs/4.2/Extensions/UInt.html
index b63c1f6d0..ad7441a75 100644
--- a/docs/4.2/Extensions/UInt.html
+++ b/docs/4.2/Extensions/UInt.html
@@ -14,7 +14,7 @@
- GRDB 4.2.0 Docs (90% documented)
+ GRDB 4.2.1 Docs (90% documented)
@@ -1075,7 +1075,7 @@
@@ -1100,12 +1100,12 @@
Declaration
Swift
- public var databaseValue: DatabaseValue { get }
+ public var databaseValue: DatabaseValue { get }
@@ -1135,7 +1135,7 @@
@@ -1145,7 +1145,7 @@
diff --git a/docs/4.2/Extensions/UInt16.html b/docs/4.2/Extensions/UInt16.html
index 7fb687324..2121ef004 100644
--- a/docs/4.2/Extensions/UInt16.html
+++ b/docs/4.2/Extensions/UInt16.html
@@ -14,7 +14,7 @@
- GRDB 4.2.0 Docs (90% documented)
+ GRDB 4.2.1 Docs (90% documented)
@@ -1075,7 +1075,7 @@
@@ -1100,12 +1100,12 @@
Declaration
Swift
- public var databaseValue: DatabaseValue { get }
+ public var databaseValue: DatabaseValue { get }
@@ -1135,7 +1135,7 @@
@@ -1145,7 +1145,7 @@
diff --git a/docs/4.2/Extensions/UInt32.html b/docs/4.2/Extensions/UInt32.html
index 1d9e51f50..31bbe7256 100644
--- a/docs/4.2/Extensions/UInt32.html
+++ b/docs/4.2/Extensions/UInt32.html
@@ -14,7 +14,7 @@
- GRDB 4.2.0 Docs (90% documented)
+ GRDB 4.2.1 Docs (90% documented)
@@ -1075,7 +1075,7 @@
@@ -1100,12 +1100,12 @@
Declaration
Swift
- public var databaseValue: DatabaseValue { get }
+ public var databaseValue: DatabaseValue { get }
@@ -1135,7 +1135,7 @@
@@ -1145,7 +1145,7 @@
diff --git a/docs/4.2/Extensions/UInt64.html b/docs/4.2/Extensions/UInt64.html
index 98ef03f24..e2d6205a8 100644
--- a/docs/4.2/Extensions/UInt64.html
+++ b/docs/4.2/Extensions/UInt64.html
@@ -14,7 +14,7 @@
- GRDB 4.2.0 Docs (90% documented)
+ GRDB 4.2.1 Docs (90% documented)
@@ -1075,7 +1075,7 @@
@@ -1100,12 +1100,12 @@
Declaration
Swift
- public var databaseValue: DatabaseValue { get }
+ public var databaseValue: DatabaseValue { get }
@@ -1135,7 +1135,7 @@
@@ -1145,7 +1145,7 @@
diff --git a/docs/4.2/Extensions/UInt8.html b/docs/4.2/Extensions/UInt8.html
index cef5e170b..0d3b04373 100644
--- a/docs/4.2/Extensions/UInt8.html
+++ b/docs/4.2/Extensions/UInt8.html
@@ -14,7 +14,7 @@
- GRDB 4.2.0 Docs (90% documented)
+ GRDB 4.2.1 Docs (90% documented)
@@ -1075,7 +1075,7 @@
@@ -1100,12 +1100,12 @@
Declaration
Swift
- public var databaseValue: DatabaseValue { get }
+ public var databaseValue: DatabaseValue { get }
@@ -1135,7 +1135,7 @@
@@ -1145,7 +1145,7 @@
diff --git a/docs/4.2/Extensions/UUID.html b/docs/4.2/Extensions/UUID.html
index 8104d2a10..d1c66048c 100644
--- a/docs/4.2/Extensions/UUID.html
+++ b/docs/4.2/Extensions/UUID.html
@@ -14,7 +14,7 @@
- GRDB 4.2.0 Docs (90% documented)
+ GRDB 4.2.1 Docs (90% documented)
@@ -1038,12 +1038,12 @@
Declaration
Swift
- public var databaseValue: DatabaseValue { get }
+ public var databaseValue: DatabaseValue { get }
@@ -1072,7 +1072,7 @@
@@ -1106,7 +1106,7 @@
@@ -1116,7 +1116,7 @@
diff --git a/docs/4.2/Functions.html b/docs/4.2/Functions.html
index ed5744ddd..e0cf47f82 100644
--- a/docs/4.2/Functions.html
+++ b/docs/4.2/Functions.html
@@ -14,7 +14,7 @@
- GRDB 4.2.0 Docs (90% documented)
+ GRDB 4.2.1 Docs (90% documented)
@@ -1032,7 +1032,7 @@ number of columns.
let sql = "SELECT 1, 2,3,4, 5,6, 7,8"
// <.><. . .><. .><. .>
let adapters = splittingRowAdapters([1, 3, 2])
-let adapter = ScopeAdapter([
+let adapter = ScopeAdapter([
"a": adapters[0],
"b": adapters[1],
"c": adapters[2],
@@ -1054,7 +1054,7 @@ number of columns.
@@ -1099,7 +1099,7 @@ number of columns.
@@ -1136,7 +1136,7 @@ number of columns.
@@ -1173,7 +1173,7 @@ number of columns.
@@ -1221,7 +1221,7 @@ number of columns.
@@ -1258,7 +1258,7 @@ number of columns.
@@ -1295,7 +1295,7 @@ number of columns.
@@ -1329,7 +1329,7 @@ number of columns.
@@ -1363,7 +1363,7 @@ number of columns.
@@ -1400,7 +1400,7 @@ number of columns.
@@ -1437,7 +1437,7 @@ number of columns.
@@ -1474,7 +1474,7 @@ number of columns.
@@ -1508,7 +1508,7 @@ number of columns.
@@ -1542,7 +1542,7 @@ number of columns.
@@ -1579,7 +1579,7 @@ number of columns.
@@ -1616,7 +1616,7 @@ number of columns.
@@ -1653,7 +1653,7 @@ number of columns.
@@ -1690,7 +1690,7 @@ number of columns.
@@ -1727,7 +1727,7 @@ number of columns.
@@ -1764,7 +1764,7 @@ number of columns.
@@ -1812,7 +1812,7 @@ number of columns.
@@ -1849,7 +1849,7 @@ number of columns.
@@ -1886,7 +1886,7 @@ number of columns.
@@ -1923,7 +1923,7 @@ number of columns.
@@ -1960,7 +1960,7 @@ number of columns.
@@ -1997,7 +1997,7 @@ number of columns.
@@ -2034,7 +2034,7 @@ number of columns.
@@ -2071,7 +2071,7 @@ number of columns.
@@ -2108,7 +2108,7 @@ number of columns.
@@ -2145,7 +2145,7 @@ number of columns.
@@ -2182,7 +2182,7 @@ number of columns.
@@ -2219,7 +2219,7 @@ number of columns.
@@ -2264,7 +2264,7 @@ number of columns.
@@ -2301,7 +2301,7 @@ number of columns.
@@ -2338,7 +2338,7 @@ number of columns.
@@ -2375,7 +2375,7 @@ number of columns.
@@ -2412,7 +2412,7 @@ number of columns.
@@ -2449,7 +2449,7 @@ number of columns.
@@ -2486,7 +2486,7 @@ number of columns.
@@ -2523,7 +2523,7 @@ number of columns.
@@ -2560,7 +2560,7 @@ number of columns.
@@ -2597,7 +2597,7 @@ number of columns.
@@ -2634,7 +2634,7 @@ number of columns.
@@ -2671,7 +2671,7 @@ number of columns.
@@ -2708,7 +2708,7 @@ number of columns.
@@ -2738,7 +2738,7 @@ number of columns.
Returns an aggregate that evaluates the IFNULL SQL function.
-Team.annotated(with: Team.players.min(Column("score")) ?? 0)
+Team.annotated(with: Team.players.min(Column("score")) ?? 0)
@@ -2754,7 +2754,7 @@ number of columns.
@@ -2785,7 +2785,7 @@ number of columns.
Returns an expression that evaluates the ABS SQL function.
// ABS(amount)
-abs(Column("amount"))
+abs(Column("amount"))
@@ -2798,7 +2798,7 @@ number of columns.
@@ -2829,7 +2829,7 @@ number of columns.
Returns an expression that evaluates the AVG SQL function.
// AVG(length)
-average(Column("length"))
+average(Column("length"))
@@ -2842,7 +2842,7 @@ number of columns.
@@ -2873,7 +2873,7 @@ number of columns.
Returns an expression that evaluates the COUNT SQL function.
// COUNT(email)
-count(Column("email"))
+count(Column("email"))
@@ -2886,7 +2886,7 @@ number of columns.
@@ -2917,7 +2917,7 @@ number of columns.
Returns an expression that evaluates the COUNT(DISTINCT) SQL function.
// COUNT(DISTINCT email)
-count(distinct: Column("email"))
+count(distinct: Column("email"))
@@ -2930,7 +2930,7 @@ number of columns.
@@ -2961,7 +2961,7 @@ number of columns.
Returns an expression that evaluates the IFNULL SQL function.
// IFNULL(name, 'Anonymous')
-Column("name") ?? "Anonymous"
+Column("name") ?? "Anonymous"
@@ -2974,7 +2974,7 @@ number of columns.
@@ -3005,7 +3005,7 @@ number of columns.
Returns an expression that evaluates the LENGTH SQL function.
// LENGTH(name)
-length(Column("name"))
+length(Column("name"))
@@ -3018,7 +3018,7 @@ number of columns.
@@ -3049,7 +3049,7 @@ number of columns.
Returns an expression that evaluates the MAX SQL function.
// MAX(score)
-max(Column("score"))
+max(Column("score"))
@@ -3062,7 +3062,7 @@ number of columns.
@@ -3093,7 +3093,7 @@ number of columns.
Returns an expression that evaluates the MIN SQL function.
// MIN(score)
-min(Column("score"))
+min(Column("score"))
@@ -3106,7 +3106,7 @@ number of columns.
@@ -3137,7 +3137,7 @@ number of columns.
Returns an expression that evaluates the SUM SQL function.
// SUM(amount)
-sum(Column("amount"))
+sum(Column("amount"))
@@ -3150,7 +3150,7 @@ number of columns.
@@ -3181,12 +3181,12 @@ number of columns.
An SQL expression that compares two expressions with the = SQL operator.
// name = 'Arthur'
-Column("name") == "Arthur"
+Column("name") == "Arthur"
When the right operand is nil, IS NULL is used instead.
// name IS NULL
-Column("name") == nil
+Column("name") == nil
@@ -3199,7 +3199,7 @@ number of columns.
@@ -3219,12 +3219,12 @@ number of columns.
An SQL expression that compares two expressions with the = SQL operator.
// name = 'Arthur' COLLATE NOCASE
-Column("name").collating(.nocase) == "Arthur"
+Column("name").collating(.nocase) == "Arthur"
When the right operand is nil, IS NULL is used instead.
// name IS NULL
-Column("name").collating(.nocase) == nil
+Column("name").collating(.nocase) == nil
@@ -3237,7 +3237,7 @@ number of columns.
@@ -3259,10 +3259,10 @@ number of columns.
The comparison is done with the built-in boolean evaluation of SQLite:
// validated
-Column("validated") == true
+Column("validated") == true
// NOT validated
-Column("validated") == false
+Column("validated") == false
@@ -3275,7 +3275,7 @@ number of columns.
@@ -3295,12 +3295,12 @@ number of columns.
An SQL expression that compares two expressions with the = SQL operator.
// 'Arthur' = name
-"Arthur" == Column("name")
+"Arthur" == Column("name")
When the left operand is nil, IS NULL is used instead.
// name IS NULL
-nil == Column("name")
+nil == Column("name")
@@ -3313,7 +3313,7 @@ number of columns.
@@ -3333,12 +3333,12 @@ number of columns.
An SQL expression that compares two expressions with the = SQL operator.
// 'Arthur' = name COLLATE NOCASE
-"Arthur" == Column("name").collating(.nocase)
+"Arthur" == Column("name").collating(.nocase)
When the left operand is nil, IS NULL is used instead.
// name IS NULL
-nil == Column("name").collating(.nocase)
+nil == Column("name").collating(.nocase)
@@ -3351,7 +3351,7 @@ number of columns.
@@ -3373,10 +3373,10 @@ number of columns.
The comparison is done with the built-in boolean evaluation of SQLite:
// validated
-true == Column("validated")
+true == Column("validated")
// NOT validated
-false == Column("validated")
+false == Column("validated")
@@ -3389,7 +3389,7 @@ number of columns.
@@ -3409,7 +3409,7 @@ number of columns.
An SQL expression that compares two expressions with the = SQL operator.
// email = login
-Column("email") == Column("login")
+Column("email") == Column("login")
@@ -3422,7 +3422,7 @@ number of columns.
@@ -3442,12 +3442,12 @@ number of columns.
An SQL expression that compares two expressions with the <> SQL operator.
// name <> 'Arthur'
-Column("name") != "Arthur"
+Column("name") != "Arthur"
When the right operand is nil, IS NOT NULL is used instead.
// name IS NOT NULL
-Column("name") != nil
+Column("name") != nil
@@ -3460,7 +3460,7 @@ number of columns.
@@ -3480,12 +3480,12 @@ number of columns.
An SQL expression that compares two expressions with the <> SQL operator.
// name <> 'Arthur' COLLATE NOCASE
-Column("name").collating(.nocase) != "Arthur"
+Column("name").collating(.nocase) != "Arthur"
When the right operand is nil, IS NOT NULL is used instead.
// name IS NOT NULL
-Column("name").collating(.nocase) != nil
+Column("name").collating(.nocase) != nil
@@ -3498,7 +3498,7 @@ number of columns.
@@ -3520,10 +3520,10 @@ number of columns.
The comparison is done with the built-in boolean evaluation of SQLite:
// NOT validated
-Column("validated") != true
+Column("validated") != true
// validated
-Column("validated") != false
+Column("validated") != false
@@ -3536,7 +3536,7 @@ number of columns.
@@ -3556,12 +3556,12 @@ number of columns.
An SQL expression that compares two expressions with the <> SQL operator.
// 'Arthur' <> name
-"Arthur" != Column("name")
+"Arthur" != Column("name")
When the left operand is nil, IS NOT NULL is used instead.
// name IS NOT NULL
-nil != Column("name")
+nil != Column("name")
@@ -3574,7 +3574,7 @@ number of columns.
@@ -3594,12 +3594,12 @@ number of columns.
An SQL expression that compares two expressions with the <> SQL operator.
// 'Arthur' <> name COLLATE NOCASE
-"Arthur" != Column("name").collating(.nocase)
+"Arthur" != Column("name").collating(.nocase)
When the left operand is nil, IS NOT NULL is used instead.
// name IS NOT NULL
-nil != Column("name").collating(.nocase)
+nil != Column("name").collating(.nocase)
@@ -3612,7 +3612,7 @@ number of columns.
@@ -3634,10 +3634,10 @@ number of columns.
The comparison is done with the built-in boolean evaluation of SQLite:
// NOT validated
-true != Column("validated")
+true != Column("validated")
// validated
-false != Column("validated")
+false != Column("validated")
@@ -3650,7 +3650,7 @@ number of columns.
@@ -3670,7 +3670,7 @@ number of columns.
An SQL expression that compares two expressions with the <> SQL operator.
// email <> login
-Column("email") != Column("login")
+Column("email") != Column("login")
@@ -3683,7 +3683,7 @@ number of columns.
@@ -3703,7 +3703,7 @@ number of columns.
An SQL expression that compares two expressions with the IS SQL operator.
// name IS 'Arthur'
-Column("name") === "Arthur"
+Column("name") === "Arthur"
@@ -3716,7 +3716,7 @@ number of columns.
@@ -3736,7 +3736,7 @@ number of columns.
An SQL expression that compares two expressions with the IS SQL operator.
// name IS 'Arthur' COLLATE NOCASE
-Column("name").collating(.nocase) === "Arthur"
+Column("name").collating(.nocase) === "Arthur"
@@ -3749,7 +3749,7 @@ number of columns.
@@ -3769,7 +3769,7 @@ number of columns.
An SQL expression that compares two expressions with the IS SQL operator.
// name IS 'Arthur'
-"Arthur" === Column("name")
+"Arthur" === Column("name")
@@ -3782,7 +3782,7 @@ number of columns.
@@ -3802,7 +3802,7 @@ number of columns.
An SQL expression that compares two expressions with the IS SQL operator.
// name IS 'Arthur' COLLATE NOCASE
-"Arthur" === Column("name").collating(.nocase)
+"Arthur" === Column("name").collating(.nocase)
@@ -3815,7 +3815,7 @@ number of columns.
@@ -3835,7 +3835,7 @@ number of columns.
An SQL expression that compares two expressions with the IS SQL operator.
// email IS login
-Column("email") === Column("login")
+Column("email") === Column("login")
@@ -3848,7 +3848,7 @@ number of columns.
@@ -3868,7 +3868,7 @@ number of columns.
An SQL expression that compares two expressions with the IS NOT SQL operator.
// name IS NOT 'Arthur'
-Column("name") !== "Arthur"
+Column("name") !== "Arthur"
@@ -3881,7 +3881,7 @@ number of columns.
@@ -3901,7 +3901,7 @@ number of columns.
An SQL expression that compares two expressions with the IS NOT SQL operator.
// name IS NOT 'Arthur' COLLATE NOCASE
-Column("name").collating(.nocase) !== "Arthur"
+Column("name").collating(.nocase) !== "Arthur"
@@ -3914,7 +3914,7 @@ number of columns.
@@ -3934,7 +3934,7 @@ number of columns.
An SQL expression that compares two expressions with the IS NOT SQL operator.
// name IS NOT 'Arthur'
-"Arthur" !== Column("name")
+"Arthur" !== Column("name")
@@ -3947,7 +3947,7 @@ number of columns.
@@ -3967,7 +3967,7 @@ number of columns.
An SQL expression that compares two expressions with the IS NOT SQL operator.
// name IS NOT 'Arthur' COLLATE NOCASE
-"Arthur" !== Column("name").collating(.nocase)
+"Arthur" !== Column("name").collating(.nocase)
@@ -3980,7 +3980,7 @@ number of columns.
@@ -4000,7 +4000,7 @@ number of columns.
An SQL expression that compares two expressions with the IS NOT SQL operator.
// email IS NOT login
-Column("email") !== Column("login")
+Column("email") !== Column("login")
@@ -4013,7 +4013,7 @@ number of columns.
@@ -4044,7 +4044,7 @@ number of columns.
An SQL expression that compares two expressions with the < SQL operator.
// score < 18
-Column("score") < 18
+Column("score") < 18
@@ -4057,7 +4057,7 @@ number of columns.
@@ -4077,7 +4077,7 @@ number of columns.
An SQL expression that compares two expressions with the < SQL operator.
// name < 'Arthur' COLLATE NOCASE
-Column("name").collating(.nocase) < "Arthur"
+Column("name").collating(.nocase) < "Arthur"
@@ -4090,7 +4090,7 @@ number of columns.
@@ -4110,7 +4110,7 @@ number of columns.
An SQL expression that compares two expressions with the < SQL operator.
// 18 < score
-18 < Column("score")
+18 < Column("score")
@@ -4123,7 +4123,7 @@ number of columns.
@@ -4143,7 +4143,7 @@ number of columns.
An SQL expression that compares two expressions with the < SQL operator.
// 'Arthur' < name COLLATE NOCASE
-"Arthur" < Column("name").collating(.nocase)
+"Arthur" < Column("name").collating(.nocase)
@@ -4156,7 +4156,7 @@ number of columns.
@@ -4176,7 +4176,7 @@ number of columns.
An SQL expression that compares two expressions with the < SQL operator.
// width < height
-Column("width") < Column("height")
+Column("width") < Column("height")
@@ -4189,7 +4189,7 @@ number of columns.
@@ -4209,7 +4209,7 @@ number of columns.
An SQL expression that compares two expressions with the <= SQL operator.
// score <= 18
-Column("score") <= 18
+Column("score") <= 18
@@ -4222,7 +4222,7 @@ number of columns.
@@ -4242,7 +4242,7 @@ number of columns.
An SQL expression that compares two expressions with the <= SQL operator.
// name <= 'Arthur' COLLATE NOCASE
-Column("name").collating(.nocase) <= "Arthur"
+Column("name").collating(.nocase) <= "Arthur"
@@ -4255,7 +4255,7 @@ number of columns.
@@ -4275,7 +4275,7 @@ number of columns.
An SQL expression that compares two expressions with the <= SQL operator.
// 18 <= score
-18 <= Column("score")
+18 <= Column("score")
@@ -4288,7 +4288,7 @@ number of columns.
@@ -4308,7 +4308,7 @@ number of columns.
An SQL expression that compares two expressions with the <= SQL operator.
// 'Arthur' <= name COLLATE NOCASE
-"Arthur" <= Column("name").collating(.nocase)
+"Arthur" <= Column("name").collating(.nocase)
@@ -4321,7 +4321,7 @@ number of columns.
@@ -4341,7 +4341,7 @@ number of columns.
An SQL expression that compares two expressions with the <= SQL operator.
// width <= height
-Column("width") <= Column("height")
+Column("width") <= Column("height")
@@ -4354,7 +4354,7 @@ number of columns.
@@ -4374,7 +4374,7 @@ number of columns.
An SQL expression that compares two expressions with the > SQL operator.
// score > 18
-Column("score") > 18
+Column("score") > 18
@@ -4387,7 +4387,7 @@ number of columns.
@@ -4407,7 +4407,7 @@ number of columns.
An SQL expression that compares two expressions with the > SQL operator.
// name > 'Arthur' COLLATE NOCASE
-Column("name").collating(.nocase) > "Arthur"
+Column("name").collating(.nocase) > "Arthur"
@@ -4420,7 +4420,7 @@ number of columns.
@@ -4440,7 +4440,7 @@ number of columns.
An SQL expression that compares two expressions with the > SQL operator.
// 18 > score
-18 > Column("score")
+18 > Column("score")
@@ -4453,7 +4453,7 @@ number of columns.
@@ -4473,7 +4473,7 @@ number of columns.
An SQL expression that compares two expressions with the > SQL operator.
// 'Arthur' > name COLLATE NOCASE
-"Arthur" > Column("name").collating(.nocase)
+"Arthur" > Column("name").collating(.nocase)
@@ -4486,7 +4486,7 @@ number of columns.
@@ -4506,7 +4506,7 @@ number of columns.
An SQL expression that compares two expressions with the > SQL operator.
// width > height
-Column("width") > Column("height")
+Column("width") > Column("height")
@@ -4519,7 +4519,7 @@ number of columns.
@@ -4539,7 +4539,7 @@ number of columns.
An SQL expression that compares two expressions with the >= SQL operator.
// score >= 18
-Column("score") >= 18
+Column("score") >= 18
@@ -4552,7 +4552,7 @@ number of columns.
@@ -4572,7 +4572,7 @@ number of columns.
An SQL expression that compares two expressions with the >= SQL operator.
// name >= 'Arthur' COLLATE NOCASE
-Column("name").collating(.nocase) >= "Arthur"
+Column("name").collating(.nocase) >= "Arthur"
@@ -4585,7 +4585,7 @@ number of columns.
@@ -4605,7 +4605,7 @@ number of columns.
An SQL expression that compares two expressions with the >= SQL operator.
// 18 >= score
-18 >= Column("score")
+18 >= Column("score")
@@ -4618,7 +4618,7 @@ number of columns.
@@ -4638,7 +4638,7 @@ number of columns.
An SQL expression that compares two expressions with the >= SQL operator.
// 'Arthur' >= name COLLATE NOCASE
-"Arthur" >= Column("name").collating(.nocase)
+"Arthur" >= Column("name").collating(.nocase)
@@ -4651,7 +4651,7 @@ number of columns.
@@ -4671,7 +4671,7 @@ number of columns.
An SQL expression that compares two expressions with the >= SQL operator.
// width >= height
-Column("width") >= Column("height")
+Column("width") >= Column("height")
@@ -4684,7 +4684,7 @@ number of columns.
@@ -4715,7 +4715,7 @@ number of columns.
An SQL arithmetic multiplication.
// width * 2
-Column("width") * 2
+Column("width") * 2
@@ -4728,7 +4728,7 @@ number of columns.
@@ -4748,7 +4748,7 @@ number of columns.
An SQL arithmetic multiplication.
// 2 * width
-2 * Column("width")
+2 * Column("width")
@@ -4761,7 +4761,7 @@ number of columns.
@@ -4781,7 +4781,7 @@ number of columns.
An SQL arithmetic multiplication.
// width * height
-Column("width") * Column("height")
+Column("width") * Column("height")
@@ -4794,7 +4794,7 @@ number of columns.
@@ -4814,7 +4814,7 @@ number of columns.
An SQL arithmetic division.
// width / 2
-Column("width") / 2
+Column("width") / 2
@@ -4827,7 +4827,7 @@ number of columns.
@@ -4847,7 +4847,7 @@ number of columns.
An SQL arithmetic division.
// 2 / width
-2 / Column("width")
+2 / Column("width")
@@ -4860,7 +4860,7 @@ number of columns.
@@ -4880,7 +4880,7 @@ number of columns.
An SQL arithmetic division.
// width / height
-Column("width") / Column("height")
+Column("width") / Column("height")
@@ -4893,7 +4893,7 @@ number of columns.
@@ -4913,7 +4913,7 @@ number of columns.
An SQL arithmetic addition.
// width + 2
-Column("width") + 2
+Column("width") + 2
@@ -4926,7 +4926,7 @@ number of columns.
@@ -4946,7 +4946,7 @@ number of columns.
An SQL arithmetic addition.
// 2 + width
-2 + Column("width")
+2 + Column("width")
@@ -4959,7 +4959,7 @@ number of columns.
@@ -4979,7 +4979,7 @@ number of columns.
An SQL arithmetic addition.
// width + height
-Column("width") + Column("height")
+Column("width") + Column("height")
@@ -4992,7 +4992,7 @@ number of columns.
@@ -5012,7 +5012,7 @@ number of columns.
A negated SQL arithmetic expression.
// -width
--Column("width")
+-Column("width")
@@ -5025,7 +5025,7 @@ number of columns.
@@ -5045,7 +5045,7 @@ number of columns.
An SQL arithmetic substraction.
// width - 2
-Column("width") - 2
+Column("width") - 2
@@ -5058,7 +5058,7 @@ number of columns.
@@ -5078,7 +5078,7 @@ number of columns.
An SQL arithmetic substraction.
// 2 - width
-2 - Column("width")
+2 - Column("width")
@@ -5091,7 +5091,7 @@ number of columns.
@@ -5111,7 +5111,7 @@ number of columns.
An SQL arithmetic substraction.
// width - height
-Column("width") - Column("height")
+Column("width") - Column("height")
@@ -5124,7 +5124,7 @@ number of columns.
@@ -5155,7 +5155,7 @@ number of columns.
A logical SQL expression with the AND SQL operator.
// favorite AND 0
-Column("favorite") && false
+Column("favorite") && false
@@ -5168,7 +5168,7 @@ number of columns.
@@ -5188,7 +5188,7 @@ number of columns.
A logical SQL expression with the AND SQL operator.
// 0 AND favorite
-false && Column("favorite")
+false && Column("favorite")
@@ -5201,7 +5201,7 @@ number of columns.
@@ -5221,7 +5221,7 @@ number of columns.
A logical SQL expression with the AND SQL operator.
// email IS NOT NULL AND favorite
-Column("email") != nil && Column("favorite")
+Column("email") != nil && Column("favorite")
@@ -5234,7 +5234,7 @@ number of columns.
@@ -5254,7 +5254,7 @@ number of columns.
A logical SQL expression with the OR SQL operator.
// favorite OR 1
-Column("favorite") || true
+Column("favorite") || true
@@ -5267,7 +5267,7 @@ number of columns.
@@ -5287,7 +5287,7 @@ number of columns.
A logical SQL expression with the OR SQL operator.
// 0 OR favorite
-true || Column("favorite")
+true || Column("favorite")
@@ -5300,7 +5300,7 @@ number of columns.
@@ -5320,7 +5320,7 @@ number of columns.
A logical SQL expression with the OR SQL operator.
// email IS NULL OR hidden
-Column("email") == nil || Column("hidden")
+Column("email") == nil || Column("hidden")
@@ -5333,7 +5333,7 @@ number of columns.
@@ -5353,12 +5353,12 @@ number of columns.
A negated logical SQL expression with the NOT SQL operator.
// NOT hidden
-!Column("hidden")
+!Column("hidden")
Some expressions may be negated with specific SQL operators:
// id NOT BETWEEN 1 AND 10
-!((1...10).contains(Column("id")))
+!((1...10).contains(Column("id")))
@@ -5371,7 +5371,7 @@ number of columns.
@@ -5415,7 +5415,7 @@ number of columns.
@@ -5425,7 +5425,7 @@ number of columns.
diff --git a/docs/4.2/Protocols.html b/docs/4.2/Protocols.html
index 57fe1c411..8a15eeacf 100644
--- a/docs/4.2/Protocols.html
+++ b/docs/4.2/Protocols.html
@@ -14,7 +14,7 @@
- GRDB 4.2.0 Docs (90% documented)
+ GRDB 4.2.1 Docs (90% documented)
@@ -1071,7 +1071,7 @@ to those defined by Swift’s Sequence protocol: contains,
@@ -1096,7 +1096,7 @@ to those defined by Swift’s Sequence protocol: contains, The protocol for custom SQLite aggregates.
For example:
-struct MySum : DatabaseAggregate {
+struct MySum : DatabaseAggregate {
var sum: Int = 0
mutating func step(_ dbValues: [DatabaseValue]) {
@@ -1105,15 +1105,15 @@ to those defined by Swift’s Sequence protocol: contains, }
}
- func finalize() -> DatabaseValueConvertible? {
+ func finalize() -> DatabaseValueConvertible? {
return sum
}
}
-let dbQueue = DatabaseQueue()
-let fn = DatabaseFunction("mysum", argumentCount: 1, aggregate: MySum.self)
+let dbQueue = DatabaseQueue()
+let fn = DatabaseFunction("mysum", argumentCount: 1, aggregate: MySum.self)
dbQueue.add(function: fn)
-try dbQueue.write { db in
+try dbQueue.write { db in
try db.execute(sql: "CREATE TABLE test(i)")
try db.execute(sql: "INSERT INTO test(i) VALUES (1)")
try db.execute(sql: "INSERT INTO test(i) VALUES (2)")
@@ -1132,7 +1132,7 @@ to those defined by Swift’s Sequence protocol: contains,
@@ -1181,7 +1181,7 @@ connections, protect yourself with transactions, and be ready to setup a
@@ -1223,7 +1223,7 @@ connections, protect yourself with transactions, and be ready to setup a
@@ -1280,7 +1280,7 @@ arrays, or single values:
@@ -1311,7 +1311,7 @@ arrays, or single values:
The protocol for all requests that fetch database rows, and tell how those
rows should be interpreted.
-struct Player: FetchableRecord { ... }
+struct Player: FetchableRecord { ... }
let request: ... // Some FetchRequest that fetches Player
try request.fetchCursor(db) // Cursor of Player
try request.fetchAll(db) // [Player]
@@ -1329,7 +1329,7 @@ rows should be interpreted.
@@ -1378,7 +1378,7 @@ connections, protect yourself with transactions, and be ready to setup a
@@ -1413,7 +1413,7 @@ together.
To use a row adapter, provide it to any method that fetches:
-let adapter = SuffixRowAdapter(fromIndex: 2)
+let adapter = SuffixRowAdapter(fromIndex: 2)
let sql = "SELECT 1 AS foo, 2 AS bar, 3 AS baz"
// [baz:3]
@@ -1431,7 +1431,7 @@ together.
@@ -1466,7 +1466,7 @@ optimization whenever direct access to SQLite is possible:
let int: Int = row[0] // there
}
let ints = Int.fetchAll(db, sql: "SELECT ...") // there
-struct Player {
+struct Player {
init(row: Row) {
name = row["name"] // there
score = row["score"] // there
@@ -1488,7 +1488,7 @@ Float, Double, String, and Bool.
@@ -1533,7 +1533,7 @@ or rollbacked on a database.
@@ -1612,11 +1612,11 @@ low-level FTS5Tokenizer.tokenize(context:flags:pText:nText:tokenCallback:).
Here is the implementation for a trivial tokenizer that wraps the
built-in ascii tokenizer without any custom processing:
-class TrivialAsciiTokenizer : FTS5WrapperTokenizer {
+class TrivialAsciiTokenizer : FTS5WrapperTokenizer {
static let name = "trivial"
let wrappedTokenizer: FTS5Tokenizer
- init(db: Database, arguments: [String]) throws {
+ init(db: Database, arguments: [String]) throws {
wrappedTokenizer = try db.makeTokenizer(.ascii())
}
@@ -1625,7 +1625,7 @@ built-in ascii tokenizer without any custom processing:
flags: FTS5TokenFlags,
for tokenization: FTS5Tokenization,
tokenCallback: FTS5WrapperTokenCallback)
- throws
+ throws
{
try tokenCallback(token, flags)
}
@@ -1676,7 +1676,7 @@ built-in methods that allow to fetch instances identified by key:
@@ -1701,18 +1701,18 @@ built-in methods that allow to fetch instances identified by key:
Adopt the ColumnExpression protocol when you define a column type.
You can, for example, define a String-based column enum:
-enum Columns: String, ColumnExpression {
+enum Columns: String, ColumnExpression {
case id, name, score
}
let arthur = try Player.filter(Columns.name == "Arthur").fetchOne(db)
You can also define a genuine column type:
-struct MyColumn: ColumnExpression {
+struct MyColumn: ColumnExpression {
var name: String
var sqlType: String
}
-let nameColumn = MyColumn(name: "name", sqlType: "VARCHAR")
+let nameColumn = MyColumn(name: "name", sqlType: "VARCHAR")
let arthur = try Player.filter(nameColumn == "Arthur").fetchOne(db)
@@ -1729,7 +1729,7 @@ built-in methods that allow to fetch instances identified by key:
@@ -1767,7 +1767,7 @@ record types.
@@ -1811,7 +1811,7 @@ record types.
@@ -1855,7 +1855,7 @@ record types.
@@ -1899,7 +1899,7 @@ FTS4 and FTS5.
@@ -1934,7 +1934,7 @@ FTS4 and FTS5.
@@ -1958,7 +1958,7 @@ FTS4 and FTS5.
Types that adopt FetchableRecord can be initialized from a database Row.
let row = try Row.fetchOne(db, sql: "SELECT ...")!
-let player = Player(row)
+let player = Player(row)
The protocol comes with built-in methods that allow to fetch cursors,
@@ -1986,7 +1986,7 @@ arrays, or single records:
@@ -2021,7 +2021,7 @@ arrays, or single records:
@@ -2068,7 +2068,7 @@ mutating methods.
@@ -2105,7 +2105,7 @@ mutating methods.
@@ -2115,7 +2115,7 @@ mutating methods.
diff --git a/docs/4.2/Protocols/Association.html b/docs/4.2/Protocols/Association.html
index ff95e6bbf..5578dae60 100644
--- a/docs/4.2/Protocols/Association.html
+++ b/docs/4.2/Protocols/Association.html
@@ -14,7 +14,7 @@
- GRDB 4.2.0 Docs (90% documented)
+ GRDB 4.2.1 Docs (90% documented)
@@ -1037,7 +1037,7 @@ record types.
The record type at the origin of the association.
In the belongsTo association below, it is Book:
-struct Book: TableRecord {
+struct Book: TableRecord {
// BelongsToAssociation<Book, Author>
static let author = belongsTo(Author.self)
}
@@ -1053,7 +1053,7 @@ record types.
@@ -1078,7 +1078,7 @@ record types.
This new key impacts how rows fetched from the resulting association
should be consumed:
-struct Player: TableRecord {
+struct Player: TableRecord {
static let team = belongsTo(Team.self)
}
@@ -1096,11 +1096,11 @@ should be consumed:
This new key helps Decodable records decode rows fetched from the
resulting association:
-struct Player: TableRecord {
+struct Player: TableRecord {
static let team = belongsTo(Team.self)
}
-struct PlayerInfo: FetchableRecord, Decodable {
+struct PlayerInfo: FetchableRecord, Decodable {
let player: Player
let team: Team
@@ -1125,7 +1125,7 @@ resulting association:
@@ -1151,14 +1151,14 @@ resulting association:
Creates an association which selects selection.
-struct Player: TableRecord {
+struct Player: TableRecord {
static let team = belongsTo(Team.self)
}
// SELECT player.*, team.color
// FROM player
// JOIN team ON team.id = player.teamId
-let association = Player.team.select([Column("color")])
+let association = Player.team.select([Column("color")])
var request = Player.including(required: association)
@@ -1167,8 +1167,8 @@ resulting association:
// FROM player
// JOIN team ON team.id = player.teamId
let association = Player.team
- .select([Column("id")])
- .select([Column("color")])
+ .select([Column("id")])
+ .select([Column("color")])
var request = Player.including(required: association)
@@ -1182,7 +1182,7 @@ resulting association:
@@ -1204,7 +1204,7 @@ resulting association:
Creates an association which appends selection.
-struct Player: TableRecord {
+struct Player: TableRecord {
static let team = belongsTo(Team.self)
}
@@ -1212,8 +1212,8 @@ resulting association:
// FROM player
// JOIN team ON team.id = player.teamId
let association = Player.team
- .select([Column("color")])
- .annotated(with: [Column("name")])
+ .select([Column("color")])
+ .annotated(with: [Column("name")])
var request = Player.including(required: association)
@@ -1227,7 +1227,7 @@ resulting association:
@@ -1250,14 +1250,14 @@ resulting association:
Creates an association with the provided predicate promise added to
the eventual set of already applied predicates.
-struct Player: TableRecord {
+struct Player: TableRecord {
static let team = belongsTo(Team.self)
}
// SELECT player.*, team.*
// FROM player
// JOIN team ON team.id = player.teamId AND 1
-let association = Player.team.filter { db in true }
+let association = Player.team.filter { db in true }
var request = Player.including(required: association)
@@ -1271,7 +1271,7 @@ the eventual set of already applied predicates.
@@ -1293,7 +1293,7 @@ the eventual set of already applied predicates.
Creates an association with the provided orderings promise.
-struct Player: TableRecord {
+struct Player: TableRecord {
static let team = belongsTo(Team.self)
}
@@ -1301,7 +1301,7 @@ the eventual set of already applied predicates.
// FROM player
// JOIN team ON team.id = player.teamId
// ORDER BY team.name
-let association = Player.team.order { _ in [Column("name")] }
+let association = Player.team.order { _ in [Column("name")] }
var request = Player.including(required: association)
@@ -1311,9 +1311,9 @@ the eventual set of already applied predicates.
// JOIN team ON team.id = player.teamId
// ORDER BY team.name
let association = Player.team
- .order{ _ in [Column("color")] }
+ .order{ _ in [Column("color")] }
.reversed()
- .order{ _ in [Column("name")] }
+ .order{ _ in [Column("name")] }
var request = Player.including(required: association)
@@ -1327,7 +1327,7 @@ the eventual set of already applied predicates.
@@ -1349,7 +1349,7 @@ the eventual set of already applied predicates.
Creates an association that reverses applied orderings.
-struct Player: TableRecord {
+struct Player: TableRecord {
static let team = belongsTo(Team.self)
}
@@ -1357,7 +1357,7 @@ the eventual set of already applied predicates.
// FROM player
// JOIN team ON team.id = player.teamId
// ORDER BY team.name DESC
-let association = Player.team.order(Column("name")).reversed()
+let association = Player.team.order(Column("name")).reversed()
var request = Player.including(required: association)
@@ -1379,7 +1379,7 @@ the eventual set of already applied predicates.
@@ -1401,14 +1401,14 @@ the eventual set of already applied predicates.
Creates an association without any ordering.
-struct Player: TableRecord {
+struct Player: TableRecord {
static let team = belongsTo(Team.self)
}
// SELECT player.*, team.*
// FROM player
// JOIN team ON team.id = player.teamId
-let association = Player.team.order(Column("name")).unordered()
+let association = Player.team.order(Column("name")).unordered()
var request = Player.including(required: association)
@@ -1422,7 +1422,7 @@ the eventual set of already applied predicates.
@@ -1448,17 +1448,17 @@ a specific database table.
In the example below, the team.color = ‘red’
condition in the where
clause could be not achieved without table aliases.
-struct Player: TableRecord {
+struct Player: TableRecord {
static let team = belongsTo(Team.self)
}
// SELECT player.*, team.*
// JOIN team ON ...
// WHERE team.color = 'red'
-let teamAlias = TableAlias()
+let teamAlias = TableAlias()
let request = Player
.including(required: Player.team.aliased(teamAlias))
- .filter(teamAlias[Column("color")] == "red")
+ .filter(teamAlias[Column("color")] == "red")
When you give a name to a table alias, you can reliably inject sql
@@ -1466,7 +1466,7 @@ snippets in your requests:
// SELECT player.*, custom.*
// JOIN team custom ON ...
// WHERE custom.color = 'red'
-let teamAlias = TableAlias(name: "custom")
+let teamAlias = TableAlias(name: "custom")
let request = Player
.including(required: Player.team.aliased(teamAlias))
.filter(sql: "custom.color = ?", arguments: ["red"])
@@ -1482,7 +1482,7 @@ snippets in your requests:
@@ -1492,7 +1492,7 @@ snippets in your requests:
diff --git a/docs/4.2/Protocols/AssociationToMany.html b/docs/4.2/Protocols/AssociationToMany.html
index 19c1a7c9f..bf8e541c9 100644
--- a/docs/4.2/Protocols/AssociationToMany.html
+++ b/docs/4.2/Protocols/AssociationToMany.html
@@ -14,7 +14,7 @@
- GRDB 4.2.0 Docs (90% documented)
+ GRDB 4.2.1 Docs (90% documented)
@@ -1054,7 +1054,7 @@
@@ -1092,7 +1092,7 @@
the association. For example:
For example:
-struct TeamInfo: FetchableRecord, Decodable {
+struct TeamInfo: FetchableRecord, Decodable {
var team: Team
var playerCount: Int
}
@@ -1112,7 +1112,7 @@ the association. For example:
-