Expose the fts5_api structure

This commit is contained in:
Gwendal Roué committed 2023-03-01 08:23:36 +01:00
1 parent b3763ad08e
commit cc567f2555
2 files changed
+12 -1

No files matched your search

+4
View File
@@ -106,6 +106,10 @@ GRDB adheres to [Semantic Versioning](https://semver.org/), with one exception:
---
## Next Release
- **New**: `FTS5.api(db)` returns a pointer to the `fts5_api` structure, useful for low-level [FTS5 customization](https://www.sqlite.org/fts5.html#extending_fts5).
## 6.8.0
Released February 24, 2023 • [diff](https://github.com/groue/GRDB.swift/compare/v6.7.0...v6.8.0)
+8 -1
View File
@@ -35,6 +35,10 @@ import Foundation
/// - ``FTS5WrapperTokenizer``
/// - ``FTS5TokenFlags``
/// - ``FTS5Tokenization``
///
/// ### Low-Level FTS5 Customization
///
/// - ``api(_:)``
public struct FTS5 {
/// Options for Latin script characters. Matches the raw "remove_diacritics"
/// tokenizer argument.
@@ -100,7 +104,10 @@ public struct FTS5 {
}
}
static func api(_ db: Database) -> UnsafePointer<fts5_api> {
/// Returns a pointer to the `fts5_api` structure.
///
/// Related SQLite documentation: <https://www.sqlite.org/fts5.html#extending_fts5>
public static func api(_ db: Database) -> UnsafePointer<fts5_api> {
// Access to FTS5 is one of the rare SQLite api which was broken in
// SQLite 3.20.0+, for security reasons:
//