diff options
| -rw-r--r-- | sqlite.zig | 8 |
1 files changed, 8 insertions, 0 deletions
| @@ -601,8 +601,16 @@ pub const Db = struct { | |||
| 601 | return Savepoint.init(self, name); | 601 | return Savepoint.init(self, name); |
| 602 | } | 602 | } |
| 603 | 603 | ||
| 604 | /// CreateFunctionFlag controls the flags used when creating a custom SQL function. | ||
| 605 | /// See https://sqlite.org/c3ref/c_deterministic.html. | ||
| 606 | /// | ||
| 607 | /// The flags SQLITE_UTF16LE, SQLITE_UTF16BE are not supported yet. SQLITE_UTF8 is the default and always on. | ||
| 608 | /// | ||
| 609 | /// TODO(vincent): allow these flags when we know how to handle UTF16 data. | ||
| 604 | pub const CreateFunctionFlag = struct { | 610 | pub const CreateFunctionFlag = struct { |
| 611 | /// Equivalent to SQLITE_DETERMINISTIC | ||
| 605 | deterministic: bool = true, | 612 | deterministic: bool = true, |
| 613 | /// Equivalent to SQLITE_DIRECTONLY | ||
| 606 | direct_only: bool = true, | 614 | direct_only: bool = true, |
| 607 | }; | 615 | }; |
| 608 | 616 | ||