DatabaseRegion documentation

This commit is contained in:
Gwendal Roué committed 2018-01-16 18:46:55 +01:00
1 parent 4bcdb91895
commit e42e74103d
2 files changed
+10 -2

No files matched your search

+10 -1
View File
@@ -29,7 +29,16 @@
/// // prints "players(*)[1]"
///
/// Database regions returned by requests can be more precise than regions
/// returned by select statements.
/// returned by select statements. Especially, regions returned by statements
/// don't know about rowids:
///
/// // A plain statement
/// let statement = db.makeSelectStatement("SELECT * FROM players WHERE id = 1")
/// statement.region // "players(*)"
///
/// // A query interface request that executes the same statement:
/// let request = Player.filter(key: 1)
/// try request.region(db) // "players(*)[1]"
public struct DatabaseRegion {
private let tableRegions: [String: TableRegion]?
private init(tableRegions: [String: TableRegion]?) {
-1
View File
@@ -10,7 +10,6 @@
- [ ] REGEXP https://www.sqlite.org/lang_expr.html
- [ ] CASE x WHEN w1 THEN r1 WHEN w2 THEN r2 ELSE r3 END https://www.sqlite.org/lang_expr.html
- [ ] Write regression tests for #156 and #157
- [ ] Improve Database.region(rowIds:in:)
GRDB 3.0