react-native-nitro-sqlite 8.2.1-nitro.1 → 9.0.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (118) hide show
  1. package/RNNitroSQLite.podspec +22 -5
  2. package/android/CMakeLists.txt +43 -5
  3. package/android/build.gradle +94 -14
  4. package/android/{src/main/cpp/cpp-adapter.cpp → cpp-adapter.cpp} +1 -1
  5. package/android/gradle.properties +5 -0
  6. package/android/src/main/java/com/margelo/rnnitrosqlite/DocPathSetter.kt +13 -0
  7. package/android/src/main/java/com/margelo/rnnitrosqlite/RNNitroSQLitePackage.kt +40 -0
  8. package/android/src/newarch/com/margelo/rnnitrosqlite/RNNitroSQLiteOnLoadModule.kt +41 -0
  9. package/android/src/oldarch/com/margelo/rnnitrosqlite/RNNitroSQLiteOnLoadModule.kt +43 -0
  10. package/cpp/operations.cpp +0 -3
  11. package/cpp/sqlite/sqlite3.c +41 -41
  12. package/cpp/sqliteExecuteBatch.cpp +0 -1
  13. package/lib/commonjs/index.js +6 -6
  14. package/lib/commonjs/index.js.map +1 -1
  15. package/lib/commonjs/nitro.js.map +1 -1
  16. package/lib/commonjs/operations/execute.js +1 -1
  17. package/lib/commonjs/operations/execute.js.map +1 -1
  18. package/lib/commonjs/operations/session.js +3 -3
  19. package/lib/commonjs/operations/session.js.map +1 -1
  20. package/lib/commonjs/operations/transaction.js +4 -7
  21. package/lib/commonjs/operations/transaction.js.map +1 -1
  22. package/lib/commonjs/specs/NativeNitroSQLiteOnLoad.ios.js.map +1 -1
  23. package/lib/commonjs/specs/NativeNitroSQLiteOnLoad.js.map +1 -1
  24. package/lib/commonjs/specs/NativeQueryResult.nitro.js.map +1 -1
  25. package/lib/commonjs/specs/NitroSQLite.nitro.js.map +1 -1
  26. package/lib/commonjs/typeORM.js +1 -1
  27. package/lib/commonjs/typeORM.js.map +1 -1
  28. package/lib/commonjs/types.js +0 -1
  29. package/lib/commonjs/types.js.map +1 -1
  30. package/lib/module/index.js +9 -7
  31. package/lib/module/index.js.map +1 -1
  32. package/lib/module/nitro.js +2 -0
  33. package/lib/module/nitro.js.map +1 -1
  34. package/lib/module/operations/execute.js +3 -1
  35. package/lib/module/operations/execute.js.map +1 -1
  36. package/lib/module/operations/session.js +5 -3
  37. package/lib/module/operations/session.js.map +1 -1
  38. package/lib/module/operations/transaction.js +6 -7
  39. package/lib/module/operations/transaction.js.map +1 -1
  40. package/lib/module/specs/NativeNitroSQLiteOnLoad.ios.js +2 -0
  41. package/lib/module/specs/NativeNitroSQLiteOnLoad.ios.js.map +1 -1
  42. package/lib/module/specs/NativeNitroSQLiteOnLoad.js +2 -0
  43. package/lib/module/specs/NativeNitroSQLiteOnLoad.js.map +1 -1
  44. package/lib/module/specs/NativeQueryResult.nitro.js +2 -0
  45. package/lib/module/specs/NativeQueryResult.nitro.js.map +1 -1
  46. package/lib/module/specs/NitroSQLite.nitro.js +2 -0
  47. package/lib/module/specs/NitroSQLite.nitro.js.map +1 -1
  48. package/lib/module/typeORM.js +3 -1
  49. package/lib/module/typeORM.js.map +1 -1
  50. package/lib/module/types.js +2 -1
  51. package/lib/module/types.js.map +1 -1
  52. package/lib/typescript/{index.d.ts → commonjs/index.d.ts} +1 -0
  53. package/lib/typescript/commonjs/index.d.ts.map +1 -0
  54. package/lib/typescript/{nitro.d.ts → commonjs/nitro.d.ts} +1 -0
  55. package/lib/typescript/commonjs/nitro.d.ts.map +1 -0
  56. package/lib/typescript/{operations → commonjs/operations}/execute.d.ts +1 -0
  57. package/lib/typescript/commonjs/operations/execute.d.ts.map +1 -0
  58. package/lib/typescript/{operations → commonjs/operations}/session.d.ts +1 -0
  59. package/lib/typescript/commonjs/operations/session.d.ts.map +1 -0
  60. package/lib/typescript/{operations → commonjs/operations}/transaction.d.ts +1 -0
  61. package/lib/typescript/commonjs/operations/transaction.d.ts.map +1 -0
  62. package/lib/typescript/commonjs/package.json +1 -0
  63. package/lib/typescript/{specs → commonjs/specs}/NativeNitroSQLiteOnLoad.d.ts +1 -0
  64. package/lib/typescript/commonjs/specs/NativeNitroSQLiteOnLoad.d.ts.map +1 -0
  65. package/lib/typescript/{specs → commonjs/specs}/NativeNitroSQLiteOnLoad.ios.d.ts +1 -0
  66. package/lib/typescript/commonjs/specs/NativeNitroSQLiteOnLoad.ios.d.ts.map +1 -0
  67. package/lib/typescript/{specs → commonjs/specs}/NativeQueryResult.nitro.d.ts +1 -0
  68. package/lib/typescript/commonjs/specs/NativeQueryResult.nitro.d.ts.map +1 -0
  69. package/lib/typescript/{specs → commonjs/specs}/NitroSQLite.nitro.d.ts +1 -0
  70. package/lib/typescript/commonjs/specs/NitroSQLite.nitro.d.ts.map +1 -0
  71. package/lib/typescript/{typeORM.d.ts → commonjs/typeORM.d.ts} +1 -0
  72. package/lib/typescript/commonjs/typeORM.d.ts.map +1 -0
  73. package/lib/typescript/{types.d.ts → commonjs/types.d.ts} +1 -0
  74. package/lib/typescript/commonjs/types.d.ts.map +1 -0
  75. package/lib/typescript/module/index.d.ts +31 -0
  76. package/lib/typescript/module/index.d.ts.map +1 -0
  77. package/lib/typescript/module/nitro.d.ts +8 -0
  78. package/lib/typescript/module/nitro.d.ts.map +1 -0
  79. package/lib/typescript/module/operations/execute.d.ts +4 -0
  80. package/lib/typescript/module/operations/execute.d.ts.map +1 -0
  81. package/lib/typescript/module/operations/session.d.ts +5 -0
  82. package/lib/typescript/module/operations/session.d.ts.map +1 -0
  83. package/lib/typescript/module/operations/transaction.d.ts +6 -0
  84. package/lib/typescript/module/operations/transaction.d.ts.map +1 -0
  85. package/lib/typescript/module/package.json +1 -0
  86. package/lib/typescript/module/specs/NativeNitroSQLiteOnLoad.d.ts +7 -0
  87. package/lib/typescript/module/specs/NativeNitroSQLiteOnLoad.d.ts.map +1 -0
  88. package/lib/typescript/module/specs/NativeNitroSQLiteOnLoad.ios.d.ts +4 -0
  89. package/lib/typescript/module/specs/NativeNitroSQLiteOnLoad.ios.d.ts.map +1 -0
  90. package/lib/typescript/module/specs/NativeQueryResult.nitro.d.ts +38 -0
  91. package/lib/typescript/module/specs/NativeQueryResult.nitro.d.ts.map +1 -0
  92. package/lib/typescript/module/specs/NitroSQLite.nitro.d.ts +20 -0
  93. package/lib/typescript/module/specs/NitroSQLite.nitro.d.ts.map +1 -0
  94. package/lib/typescript/module/typeORM.d.ts +20 -0
  95. package/lib/typescript/module/typeORM.d.ts.map +1 -0
  96. package/lib/typescript/module/types.d.ts +80 -0
  97. package/lib/typescript/module/types.d.ts.map +1 -0
  98. package/nitrogen/generated/android/RNNitroSQLite+autolinking.cmake +13 -1
  99. package/nitrogen/generated/android/RNNitroSQLite+autolinking.gradle +2 -0
  100. package/nitrogen/generated/ios/RNNitroSQLite+autolinking.rb +6 -4
  101. package/nitrogen/generated/ios/RNNitroSQLite-Swift-Cxx-Bridge.cpp +9 -0
  102. package/nitrogen/generated/ios/RNNitroSQLite-Swift-Cxx-Bridge.hpp +5 -281
  103. package/nitrogen/generated/ios/RNNitroSQLite-Swift-Cxx-Umbrella.hpp +3 -35
  104. package/nitrogen/generated/ios/RNNitroSQLiteAutolinking.swift +2 -0
  105. package/package.json +86 -44
  106. package/src/operations/transaction.ts +2 -3
  107. package/src/types.ts +0 -1
  108. package/android/.gradle/8.9/checksums/checksums.lock +0 -0
  109. package/android/.gradle/8.9/dependencies-accessors/gc.properties +0 -0
  110. package/android/.gradle/8.9/fileChanges/last-build.bin +0 -0
  111. package/android/.gradle/8.9/fileHashes/fileHashes.lock +0 -0
  112. package/android/.gradle/8.9/gc.properties +0 -0
  113. package/android/.gradle/buildOutputCleanup/buildOutputCleanup.lock +0 -0
  114. package/android/.gradle/buildOutputCleanup/cache.properties +0 -2
  115. package/android/.gradle/vcs-1/gc.properties +0 -0
  116. package/android/src/main/java/com/margelo/rnnitrosqlite/RNNitroSQLiteOnLoadModule.java +0 -57
  117. package/android/src/main/java/com/margelo/rnnitrosqlite/RNNitroSQLitePackage.java +0 -48
  118. package/lib/tsconfig.tsbuildinfo +0 -1
@@ -0,0 +1,80 @@
1
+ export interface NitroSQLiteConnectionOptions {
2
+ name: string;
3
+ location?: string;
4
+ }
5
+ export interface NitroSQLiteConnection {
6
+ close(): void;
7
+ delete(): void;
8
+ attach(dbNameToAttach: string, alias: string, location?: string): void;
9
+ detach(alias: string): void;
10
+ transaction(fn: (tx: Transaction) => Promise<void> | void): Promise<void>;
11
+ execute: ExecuteQuery;
12
+ executeAsync: ExecuteAsyncQuery;
13
+ executeBatch(commands: BatchQueryCommand[]): BatchQueryResult;
14
+ executeBatchAsync(commands: BatchQueryCommand[]): Promise<BatchQueryResult>;
15
+ loadFile(location: string): FileLoadResult;
16
+ loadFileAsync(location: string): Promise<FileLoadResult>;
17
+ }
18
+ export declare enum ColumnType {
19
+ BOOLEAN = 0,
20
+ NUMBER = 1,
21
+ INT64 = 2,
22
+ TEXT = 3,
23
+ ARRAY_BUFFER = 4,
24
+ NULL_VALUE = 5
25
+ }
26
+ /**
27
+ * Represents a value that can be stored in a SQLite database
28
+ */
29
+ export type SQLiteValue = boolean | number | bigint | string | ArrayBuffer | undefined;
30
+ export type SQLiteItem = Record<string, SQLiteValue>;
31
+ export interface QueryResult<RowData extends SQLiteItem = SQLiteItem> {
32
+ readonly insertId?: number;
33
+ readonly rowsAffected: number;
34
+ readonly rows?: {
35
+ /** Raw array with all dataset */
36
+ _array: RowData[];
37
+ /** The lengh of the dataset */
38
+ length: number;
39
+ /** A convenience function to acess the index based the row object
40
+ * @param idx the row index
41
+ * @returns the row structure identified by column names
42
+ */
43
+ item: (idx: number) => RowData | undefined;
44
+ };
45
+ }
46
+ export type SQLiteQueryParams = SQLiteValue[];
47
+ export type ExecuteQuery = <RowData extends SQLiteItem = SQLiteItem>(query: string, params?: SQLiteQueryParams) => QueryResult<RowData>;
48
+ export type ExecuteAsyncQuery = <RowData extends SQLiteItem = SQLiteItem>(query: string, params?: SQLiteQueryParams) => Promise<QueryResult<RowData>>;
49
+ export interface Transaction {
50
+ commit(): QueryResult;
51
+ rollback(): QueryResult;
52
+ execute: ExecuteQuery;
53
+ executeAsync: ExecuteAsyncQuery;
54
+ }
55
+ /**
56
+ * Allows the execution of bulk of sql commands
57
+ * inside a transaction
58
+ * If a single query must be executed many times with different arguments, its preferred
59
+ * to declare it a single time, and use an array of array parameters.
60
+ */
61
+ export interface BatchQueryCommand {
62
+ query: string;
63
+ params?: SQLiteQueryParams | SQLiteQueryParams[];
64
+ }
65
+ /**
66
+ * status: 0 or undefined for correct execution, 1 for error
67
+ * message: if status === 1, here you will find error description
68
+ * rowsAffected: Number of affected rows if status == 0
69
+ */
70
+ export interface BatchQueryResult {
71
+ rowsAffected?: number;
72
+ }
73
+ /**
74
+ * Result of loading a file and executing every line as a SQL command
75
+ * Similar to BatchQueryResult
76
+ */
77
+ export interface FileLoadResult extends BatchQueryResult {
78
+ commands?: number;
79
+ }
80
+ //# sourceMappingURL=types.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../../src/types.ts"],"names":[],"mappings":"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"}
@@ -43,6 +43,18 @@ target_link_libraries(
43
43
  RNNitroSQLite
44
44
  fbjni::fbjni # <-- Facebook C++ JNI helpers
45
45
  ReactAndroid::jsi # <-- RN: JSI
46
- ReactAndroid::react_nativemodule_core # <-- RN: TurboModules Core
47
46
  react-native-nitro-modules::NitroModules # <-- NitroModules Core :)
48
47
  )
48
+
49
+ # Link react-native (different prefab between RN 0.75 and RN 0.76)
50
+ if(ReactAndroid_VERSION_MINOR GREATER_EQUAL 76)
51
+ target_link_libraries(
52
+ RNNitroSQLite
53
+ ReactAndroid::reactnative # <-- RN: Native Modules umbrella prefab
54
+ )
55
+ else()
56
+ target_link_libraries(
57
+ RNNitroSQLite
58
+ ReactAndroid::react_nativemodule_core # <-- RN: TurboModules Core
59
+ )
60
+ endif()
@@ -13,6 +13,8 @@
13
13
  /// apply from: '../nitrogen/generated/android/RNNitroSQLite+autolinking.gradle'
14
14
  /// ```
15
15
 
16
+ logger.warn("[NitroModules] 🔥 RNNitroSQLite is boosted by nitro!")
17
+
16
18
  android {
17
19
  sourceSets {
18
20
  main {
@@ -20,11 +20,11 @@
20
20
  # ```
21
21
 
22
22
  def add_nitrogen_files(spec)
23
- Pod::UI.puts "[NitroModules] Adding RNNitroSQLite specs..."
23
+ Pod::UI.puts "[NitroModules] 🔥 RNNitroSQLite is boosted by nitro!"
24
24
 
25
25
  spec.dependency "NitroModules"
26
26
 
27
- current_source_files = spec.attributes_hash['source_files'] || []
27
+ current_source_files = Array(spec.attributes_hash['source_files'])
28
28
  spec.source_files = current_source_files + [
29
29
  # Generated cross-platform specs
30
30
  "nitrogen/generated/shared/**/*.{h,hpp,c,cpp,swift}",
@@ -32,7 +32,7 @@ def add_nitrogen_files(spec)
32
32
  "nitrogen/generated/ios/**/*.{h,hpp,c,cpp,mm,swift}",
33
33
  ]
34
34
 
35
- current_public_header_files = spec.attributes_hash['public_header_files'] || []
35
+ current_public_header_files = Array(spec.attributes_hash['public_header_files'])
36
36
  spec.public_header_files = current_public_header_files + [
37
37
  # Generated specs
38
38
  "nitrogen/generated/shared/**/*.{h,hpp}",
@@ -40,7 +40,7 @@ def add_nitrogen_files(spec)
40
40
  "nitrogen/generated/ios/RNNitroSQLite-Swift-Cxx-Bridge.hpp"
41
41
  ]
42
42
 
43
- current_private_header_files = spec.attributes_hash['private_header_files'] || []
43
+ current_private_header_files = Array(spec.attributes_hash['private_header_files'])
44
44
  spec.private_header_files = current_private_header_files + [
45
45
  # iOS specific specs
46
46
  "nitrogen/generated/ios/c++/**/*.{h,hpp}",
@@ -52,5 +52,7 @@ def add_nitrogen_files(spec)
52
52
  "CLANG_CXX_LANGUAGE_STANDARD" => "c++20",
53
53
  # Enables C++ <-> Swift interop (by default it's only C)
54
54
  "SWIFT_OBJC_INTEROP_MODE" => "objcxx",
55
+ # Enables stricter modular headers
56
+ "DEFINES_MODULE" => "YES",
55
57
  })
56
58
  end
@@ -6,3 +6,12 @@
6
6
  ///
7
7
 
8
8
  #include "RNNitroSQLite-Swift-Cxx-Bridge.hpp"
9
+
10
+ // Include C++ implementation defined types
11
+
12
+
13
+ namespace margelo::nitro::rnnitrosqlite::bridge::swift {
14
+
15
+
16
+
17
+ } // namespace margelo::nitro::rnnitrosqlite::bridge::swift
@@ -8,77 +8,13 @@
8
8
  #pragma once
9
9
 
10
10
  // Forward declarations of C++ defined types
11
- // Forward declaration of `ArrayBufferHolder` to properly resolve imports.
12
- namespace NitroModules { class ArrayBufferHolder; }
13
- // Forward declaration of `ArrayBuffer` to properly resolve imports.
14
- namespace NitroModules { class ArrayBuffer; }
15
- // Forward declaration of `BatchQueryCommand` to properly resolve imports.
16
- namespace margelo::nitro::rnnitrosqlite { struct BatchQueryCommand; }
17
- // Forward declaration of `BatchQueryResult` to properly resolve imports.
18
- namespace margelo::nitro::rnnitrosqlite { struct BatchQueryResult; }
19
- // Forward declaration of `ColumnType` to properly resolve imports.
20
- namespace margelo::nitro::rnnitrosqlite { enum class ColumnType; }
21
- // Forward declaration of `FileLoadResult` to properly resolve imports.
22
- namespace margelo::nitro::rnnitrosqlite { struct FileLoadResult; }
23
- // Forward declaration of `HybridNativeQueryResultSpecSwift` to properly resolve imports.
24
- namespace margelo::nitro::rnnitrosqlite { class HybridNativeQueryResultSpecSwift; }
25
- // Forward declaration of `HybridNativeQueryResultSpec` to properly resolve imports.
26
- namespace margelo::nitro::rnnitrosqlite { class HybridNativeQueryResultSpec; }
27
- // Forward declaration of `SQLiteQueryColumnMetadata` to properly resolve imports.
28
- namespace margelo::nitro::rnnitrosqlite { struct SQLiteQueryColumnMetadata; }
11
+
12
+
13
+ // Forward declarations of Swift defined types
14
+
29
15
 
30
16
  // Include C++ defined types
31
- #if __has_include("BatchQueryCommand.hpp")
32
- #include "BatchQueryCommand.hpp"
33
- #endif
34
- #if __has_include("BatchQueryResult.hpp")
35
- #include "BatchQueryResult.hpp"
36
- #endif
37
- #if __has_include("ColumnType.hpp")
38
- #include "ColumnType.hpp"
39
- #endif
40
- #if __has_include("FileLoadResult.hpp")
41
- #include "FileLoadResult.hpp"
42
- #endif
43
- #if __has_include("HybridNativeQueryResultSpec.hpp")
44
- #include "HybridNativeQueryResultSpec.hpp"
45
- #endif
46
- #if __has_include("HybridNativeQueryResultSpecSwift.hpp")
47
- #include "HybridNativeQueryResultSpecSwift.hpp"
48
- #endif
49
- #if __has_include("SQLiteQueryColumnMetadata.hpp")
50
- #include "SQLiteQueryColumnMetadata.hpp"
51
- #endif
52
- #if __has_include(<NitroModules/ArrayBuffer.hpp>)
53
- #include <NitroModules/ArrayBuffer.hpp>
54
- #endif
55
- #if __has_include(<NitroModules/ArrayBufferHolder.hpp>)
56
- #include <NitroModules/ArrayBufferHolder.hpp>
57
- #endif
58
- #if __has_include(<NitroModules/PromiseHolder.hpp>)
59
- #include <NitroModules/PromiseHolder.hpp>
60
- #endif
61
- #if __has_include(<future>)
62
- #include <future>
63
- #endif
64
- #if __has_include(<memory>)
65
- #include <memory>
66
- #endif
67
- #if __has_include(<optional>)
68
- #include <optional>
69
- #endif
70
- #if __has_include(<string>)
71
- #include <string>
72
- #endif
73
- #if __has_include(<unordered_map>)
74
- #include <unordered_map>
75
- #endif
76
- #if __has_include(<variant>)
77
- #include <variant>
78
- #endif
79
- #if __has_include(<vector>)
80
- #include <vector>
81
- #endif
17
+
82
18
 
83
19
  /**
84
20
  * Contains specialized versions of C++ templated types so they can be accessed from Swift,
@@ -86,218 +22,6 @@ namespace margelo::nitro::rnnitrosqlite { struct SQLiteQueryColumnMetadata; }
86
22
  */
87
23
  namespace margelo::nitro::rnnitrosqlite::bridge::swift {
88
24
 
89
- /**
90
- * Specialized version of `std::optional<double>`.
91
- */
92
- using std__optional_double_ = std::optional<double>;
93
- inline std::optional<double> create_std__optional_double_(const double& value) {
94
- return std::optional<double>(value);
95
- }
96
-
97
- /**
98
- * Wrapper struct for `std::variant<std::string, double, int64_t, bool, std::shared_ptr<ArrayBuffer>>`.
99
- * std::variant cannot be used in Swift because of a Swift bug.
100
- * Not even specializing it works. So we create a wrapper struct.
101
- */
102
- struct std__variant_std__string__double__int64_t__bool__std__shared_ptr_ArrayBuffer__ {
103
- std::variant<std::string, double, int64_t, bool, std::shared_ptr<ArrayBuffer>> variant;
104
- std__variant_std__string__double__int64_t__bool__std__shared_ptr_ArrayBuffer__(std::variant<std::string, double, int64_t, bool, std::shared_ptr<ArrayBuffer>> variant): variant(variant) { }
105
- operator std::variant<std::string, double, int64_t, bool, std::shared_ptr<ArrayBuffer>>() const {
106
- return variant;
107
- }
108
- inline size_t index() const {
109
- return variant.index();
110
- }
111
- };
112
- inline std__variant_std__string__double__int64_t__bool__std__shared_ptr_ArrayBuffer__ create_std__variant_std__string__double__int64_t__bool__std__shared_ptr_ArrayBuffer__(const std::string& value) {
113
- return std__variant_std__string__double__int64_t__bool__std__shared_ptr_ArrayBuffer__(value);
114
- }
115
- inline std__variant_std__string__double__int64_t__bool__std__shared_ptr_ArrayBuffer__ create_std__variant_std__string__double__int64_t__bool__std__shared_ptr_ArrayBuffer__(double value) {
116
- return std__variant_std__string__double__int64_t__bool__std__shared_ptr_ArrayBuffer__(value);
117
- }
118
- inline std__variant_std__string__double__int64_t__bool__std__shared_ptr_ArrayBuffer__ create_std__variant_std__string__double__int64_t__bool__std__shared_ptr_ArrayBuffer__(int64_t value) {
119
- return std__variant_std__string__double__int64_t__bool__std__shared_ptr_ArrayBuffer__(value);
120
- }
121
- inline std__variant_std__string__double__int64_t__bool__std__shared_ptr_ArrayBuffer__ create_std__variant_std__string__double__int64_t__bool__std__shared_ptr_ArrayBuffer__(bool value) {
122
- return std__variant_std__string__double__int64_t__bool__std__shared_ptr_ArrayBuffer__(value);
123
- }
124
- inline std__variant_std__string__double__int64_t__bool__std__shared_ptr_ArrayBuffer__ create_std__variant_std__string__double__int64_t__bool__std__shared_ptr_ArrayBuffer__(const std::shared_ptr<ArrayBuffer>& value) {
125
- return std__variant_std__string__double__int64_t__bool__std__shared_ptr_ArrayBuffer__(value);
126
- }
127
- inline std::string get_std__variant_std__string__double__int64_t__bool__std__shared_ptr_ArrayBuffer___0(const std__variant_std__string__double__int64_t__bool__std__shared_ptr_ArrayBuffer__& variantWrapper) {
128
- return std::get<0>(variantWrapper.variant);
129
- }
130
- inline double get_std__variant_std__string__double__int64_t__bool__std__shared_ptr_ArrayBuffer___1(const std__variant_std__string__double__int64_t__bool__std__shared_ptr_ArrayBuffer__& variantWrapper) {
131
- return std::get<1>(variantWrapper.variant);
132
- }
133
- inline int64_t get_std__variant_std__string__double__int64_t__bool__std__shared_ptr_ArrayBuffer___2(const std__variant_std__string__double__int64_t__bool__std__shared_ptr_ArrayBuffer__& variantWrapper) {
134
- return std::get<2>(variantWrapper.variant);
135
- }
136
- inline bool get_std__variant_std__string__double__int64_t__bool__std__shared_ptr_ArrayBuffer___3(const std__variant_std__string__double__int64_t__bool__std__shared_ptr_ArrayBuffer__& variantWrapper) {
137
- return std::get<3>(variantWrapper.variant);
138
- }
139
- inline std::shared_ptr<ArrayBuffer> get_std__variant_std__string__double__int64_t__bool__std__shared_ptr_ArrayBuffer___4(const std__variant_std__string__double__int64_t__bool__std__shared_ptr_ArrayBuffer__& variantWrapper) {
140
- return std::get<4>(variantWrapper.variant);
141
- }
142
-
143
- /**
144
- * Specialized version of `std::unordered_map<std::string, std::variant<std::string, double, int64_t, bool, std::shared_ptr<ArrayBuffer>>>`.
145
- */
146
- using std__unordered_map_std__string__std__variant_std__string__double__int64_t__bool__std__shared_ptr_ArrayBuffer___ = std::unordered_map<std::string, std::variant<std::string, double, int64_t, bool, std::shared_ptr<ArrayBuffer>>>;
147
- inline std::unordered_map<std::string, std::variant<std::string, double, int64_t, bool, std::shared_ptr<ArrayBuffer>>> create_std__unordered_map_std__string__std__variant_std__string__double__int64_t__bool__std__shared_ptr_ArrayBuffer___(size_t size) {
148
- std::unordered_map<std::string, std::variant<std::string, double, int64_t, bool, std::shared_ptr<ArrayBuffer>>> map;
149
- map.reserve(size);
150
- return map;
151
- }
152
- inline std::vector<std::string> get_std__unordered_map_std__string__std__variant_std__string__double__int64_t__bool__std__shared_ptr_ArrayBuffer____keys(const std__unordered_map_std__string__std__variant_std__string__double__int64_t__bool__std__shared_ptr_ArrayBuffer___& map) {
153
- std::vector<std::string> keys;
154
- keys.reserve(map.size());
155
- for (const auto& entry : map) {
156
- keys.push_back(entry.first);
157
- }
158
- return keys;
159
- }
160
-
161
- /**
162
- * Specialized version of `std::vector<std::unordered_map<std::string, std::variant<std::string, double, int64_t, bool, std::shared_ptr<ArrayBuffer>>>>`.
163
- */
164
- using std__vector_std__unordered_map_std__string__std__variant_std__string__double__int64_t__bool__std__shared_ptr_ArrayBuffer____ = std::vector<std::unordered_map<std::string, std::variant<std::string, double, int64_t, bool, std::shared_ptr<ArrayBuffer>>>>;
165
- inline std::vector<std::unordered_map<std::string, std::variant<std::string, double, int64_t, bool, std::shared_ptr<ArrayBuffer>>>> create_std__vector_std__unordered_map_std__string__std__variant_std__string__double__int64_t__bool__std__shared_ptr_ArrayBuffer____(size_t size) {
166
- std::vector<std::unordered_map<std::string, std::variant<std::string, double, int64_t, bool, std::shared_ptr<ArrayBuffer>>>> vector;
167
- vector.reserve(size);
168
- return vector;
169
- }
170
-
171
- /**
172
- * Specialized version of `std::unordered_map<std::string, SQLiteQueryColumnMetadata>`.
173
- */
174
- using std__unordered_map_std__string__SQLiteQueryColumnMetadata_ = std::unordered_map<std::string, SQLiteQueryColumnMetadata>;
175
- inline std::unordered_map<std::string, SQLiteQueryColumnMetadata> create_std__unordered_map_std__string__SQLiteQueryColumnMetadata_(size_t size) {
176
- std::unordered_map<std::string, SQLiteQueryColumnMetadata> map;
177
- map.reserve(size);
178
- return map;
179
- }
180
- inline std::vector<std::string> get_std__unordered_map_std__string__SQLiteQueryColumnMetadata__keys(const std__unordered_map_std__string__SQLiteQueryColumnMetadata_& map) {
181
- std::vector<std::string> keys;
182
- keys.reserve(map.size());
183
- for (const auto& entry : map) {
184
- keys.push_back(entry.first);
185
- }
186
- return keys;
187
- }
188
-
189
- /**
190
- * Specialized version of `std::optional<std::unordered_map<std::string, SQLiteQueryColumnMetadata>>`.
191
- */
192
- using std__optional_std__unordered_map_std__string__SQLiteQueryColumnMetadata__ = std::optional<std::unordered_map<std::string, SQLiteQueryColumnMetadata>>;
193
- inline std::optional<std::unordered_map<std::string, SQLiteQueryColumnMetadata>> create_std__optional_std__unordered_map_std__string__SQLiteQueryColumnMetadata__(const std::unordered_map<std::string, SQLiteQueryColumnMetadata>& value) {
194
- return std::optional<std::unordered_map<std::string, SQLiteQueryColumnMetadata>>(value);
195
- }
196
-
197
- /**
198
- * Specialized version of `std::optional<std::string>`.
199
- */
200
- using std__optional_std__string_ = std::optional<std::string>;
201
- inline std::optional<std::string> create_std__optional_std__string_(const std::string& value) {
202
- return std::optional<std::string>(value);
203
- }
204
-
205
- /**
206
- * Specialized version of `std::vector<std::variant<std::string, double, int64_t, bool, std::shared_ptr<ArrayBuffer>>>`.
207
- */
208
- using std__vector_std__variant_std__string__double__int64_t__bool__std__shared_ptr_ArrayBuffer___ = std::vector<std::variant<std::string, double, int64_t, bool, std::shared_ptr<ArrayBuffer>>>;
209
- inline std::vector<std::variant<std::string, double, int64_t, bool, std::shared_ptr<ArrayBuffer>>> create_std__vector_std__variant_std__string__double__int64_t__bool__std__shared_ptr_ArrayBuffer___(size_t size) {
210
- std::vector<std::variant<std::string, double, int64_t, bool, std::shared_ptr<ArrayBuffer>>> vector;
211
- vector.reserve(size);
212
- return vector;
213
- }
214
-
215
- /**
216
- * Specialized version of `std::optional<std::vector<std::variant<std::string, double, int64_t, bool, std::shared_ptr<ArrayBuffer>>>>`.
217
- */
218
- using std__optional_std__vector_std__variant_std__string__double__int64_t__bool__std__shared_ptr_ArrayBuffer____ = std::optional<std::vector<std::variant<std::string, double, int64_t, bool, std::shared_ptr<ArrayBuffer>>>>;
219
- inline std::optional<std::vector<std::variant<std::string, double, int64_t, bool, std::shared_ptr<ArrayBuffer>>>> create_std__optional_std__vector_std__variant_std__string__double__int64_t__bool__std__shared_ptr_ArrayBuffer____(const std::vector<std::variant<std::string, double, int64_t, bool, std::shared_ptr<ArrayBuffer>>>& value) {
220
- return std::optional<std::vector<std::variant<std::string, double, int64_t, bool, std::shared_ptr<ArrayBuffer>>>>(value);
221
- }
222
-
223
- /**
224
- * Specialized version of `PromiseHolder<std::shared_ptr<margelo::nitro::rnnitrosqlite::HybridNativeQueryResultSpec>>`.
225
- */
226
- using PromiseHolder_std__shared_ptr_margelo__nitro__rnnitrosqlite__HybridNativeQueryResultSpec__ = PromiseHolder<std::shared_ptr<margelo::nitro::rnnitrosqlite::HybridNativeQueryResultSpec>>;
227
- inline PromiseHolder<std::shared_ptr<margelo::nitro::rnnitrosqlite::HybridNativeQueryResultSpec>> create_PromiseHolder_std__shared_ptr_margelo__nitro__rnnitrosqlite__HybridNativeQueryResultSpec__() {
228
- return PromiseHolder<std::shared_ptr<margelo::nitro::rnnitrosqlite::HybridNativeQueryResultSpec>>();
229
- }
230
-
231
- /**
232
- * Specialized version of `std::vector<std::vector<std::variant<std::string, double, int64_t, bool, std::shared_ptr<ArrayBuffer>>>>`.
233
- */
234
- using std__vector_std__vector_std__variant_std__string__double__int64_t__bool__std__shared_ptr_ArrayBuffer____ = std::vector<std::vector<std::variant<std::string, double, int64_t, bool, std::shared_ptr<ArrayBuffer>>>>;
235
- inline std::vector<std::vector<std::variant<std::string, double, int64_t, bool, std::shared_ptr<ArrayBuffer>>>> create_std__vector_std__vector_std__variant_std__string__double__int64_t__bool__std__shared_ptr_ArrayBuffer____(size_t size) {
236
- std::vector<std::vector<std::variant<std::string, double, int64_t, bool, std::shared_ptr<ArrayBuffer>>>> vector;
237
- vector.reserve(size);
238
- return vector;
239
- }
240
-
241
- /**
242
- * Wrapper struct for `std::variant<std::vector<std::variant<std::string, double, int64_t, bool, std::shared_ptr<ArrayBuffer>>>, std::vector<std::vector<std::variant<std::string, double, int64_t, bool, std::shared_ptr<ArrayBuffer>>>>>`.
243
- * std::variant cannot be used in Swift because of a Swift bug.
244
- * Not even specializing it works. So we create a wrapper struct.
245
- */
246
- struct std__variant_std__vector_std__variant_std__string__double__int64_t__bool__std__shared_ptr_ArrayBuffer_____std__vector_std__vector_std__variant_std__string__double__int64_t__bool__std__shared_ptr_ArrayBuffer_____ {
247
- std::variant<std::vector<std::variant<std::string, double, int64_t, bool, std::shared_ptr<ArrayBuffer>>>, std::vector<std::vector<std::variant<std::string, double, int64_t, bool, std::shared_ptr<ArrayBuffer>>>>> variant;
248
- std__variant_std__vector_std__variant_std__string__double__int64_t__bool__std__shared_ptr_ArrayBuffer_____std__vector_std__vector_std__variant_std__string__double__int64_t__bool__std__shared_ptr_ArrayBuffer_____(std::variant<std::vector<std::variant<std::string, double, int64_t, bool, std::shared_ptr<ArrayBuffer>>>, std::vector<std::vector<std::variant<std::string, double, int64_t, bool, std::shared_ptr<ArrayBuffer>>>>> variant): variant(variant) { }
249
- operator std::variant<std::vector<std::variant<std::string, double, int64_t, bool, std::shared_ptr<ArrayBuffer>>>, std::vector<std::vector<std::variant<std::string, double, int64_t, bool, std::shared_ptr<ArrayBuffer>>>>>() const {
250
- return variant;
251
- }
252
- inline size_t index() const {
253
- return variant.index();
254
- }
255
- };
256
- inline std__variant_std__vector_std__variant_std__string__double__int64_t__bool__std__shared_ptr_ArrayBuffer_____std__vector_std__vector_std__variant_std__string__double__int64_t__bool__std__shared_ptr_ArrayBuffer_____ create_std__variant_std__vector_std__variant_std__string__double__int64_t__bool__std__shared_ptr_ArrayBuffer_____std__vector_std__vector_std__variant_std__string__double__int64_t__bool__std__shared_ptr_ArrayBuffer_____(const std::vector<std::variant<std::string, double, int64_t, bool, std::shared_ptr<ArrayBuffer>>>& value) {
257
- return std__variant_std__vector_std__variant_std__string__double__int64_t__bool__std__shared_ptr_ArrayBuffer_____std__vector_std__vector_std__variant_std__string__double__int64_t__bool__std__shared_ptr_ArrayBuffer_____(value);
258
- }
259
- inline std__variant_std__vector_std__variant_std__string__double__int64_t__bool__std__shared_ptr_ArrayBuffer_____std__vector_std__vector_std__variant_std__string__double__int64_t__bool__std__shared_ptr_ArrayBuffer_____ create_std__variant_std__vector_std__variant_std__string__double__int64_t__bool__std__shared_ptr_ArrayBuffer_____std__vector_std__vector_std__variant_std__string__double__int64_t__bool__std__shared_ptr_ArrayBuffer_____(const std::vector<std::vector<std::variant<std::string, double, int64_t, bool, std::shared_ptr<ArrayBuffer>>>>& value) {
260
- return std__variant_std__vector_std__variant_std__string__double__int64_t__bool__std__shared_ptr_ArrayBuffer_____std__vector_std__vector_std__variant_std__string__double__int64_t__bool__std__shared_ptr_ArrayBuffer_____(value);
261
- }
262
- inline std::vector<std::variant<std::string, double, int64_t, bool, std::shared_ptr<ArrayBuffer>>> get_std__variant_std__vector_std__variant_std__string__double__int64_t__bool__std__shared_ptr_ArrayBuffer_____std__vector_std__vector_std__variant_std__string__double__int64_t__bool__std__shared_ptr_ArrayBuffer______0(const std__variant_std__vector_std__variant_std__string__double__int64_t__bool__std__shared_ptr_ArrayBuffer_____std__vector_std__vector_std__variant_std__string__double__int64_t__bool__std__shared_ptr_ArrayBuffer_____& variantWrapper) {
263
- return std::get<0>(variantWrapper.variant);
264
- }
265
- inline std::vector<std::vector<std::variant<std::string, double, int64_t, bool, std::shared_ptr<ArrayBuffer>>>> get_std__variant_std__vector_std__variant_std__string__double__int64_t__bool__std__shared_ptr_ArrayBuffer_____std__vector_std__vector_std__variant_std__string__double__int64_t__bool__std__shared_ptr_ArrayBuffer______1(const std__variant_std__vector_std__variant_std__string__double__int64_t__bool__std__shared_ptr_ArrayBuffer_____std__vector_std__vector_std__variant_std__string__double__int64_t__bool__std__shared_ptr_ArrayBuffer_____& variantWrapper) {
266
- return std::get<1>(variantWrapper.variant);
267
- }
268
-
269
- /**
270
- * Specialized version of `std::optional<std::variant<std::vector<std::variant<std::string, double, int64_t, bool, std::shared_ptr<ArrayBuffer>>>, std::vector<std::vector<std::variant<std::string, double, int64_t, bool, std::shared_ptr<ArrayBuffer>>>>>>`.
271
- */
272
- using std__optional_std__variant_std__vector_std__variant_std__string__double__int64_t__bool__std__shared_ptr_ArrayBuffer_____std__vector_std__vector_std__variant_std__string__double__int64_t__bool__std__shared_ptr_ArrayBuffer______ = std::optional<std::variant<std::vector<std::variant<std::string, double, int64_t, bool, std::shared_ptr<ArrayBuffer>>>, std::vector<std::vector<std::variant<std::string, double, int64_t, bool, std::shared_ptr<ArrayBuffer>>>>>>;
273
- inline std::optional<std::variant<std::vector<std::variant<std::string, double, int64_t, bool, std::shared_ptr<ArrayBuffer>>>, std::vector<std::vector<std::variant<std::string, double, int64_t, bool, std::shared_ptr<ArrayBuffer>>>>>> create_std__optional_std__variant_std__vector_std__variant_std__string__double__int64_t__bool__std__shared_ptr_ArrayBuffer_____std__vector_std__vector_std__variant_std__string__double__int64_t__bool__std__shared_ptr_ArrayBuffer______(const std::variant<std::vector<std::variant<std::string, double, int64_t, bool, std::shared_ptr<ArrayBuffer>>>, std::vector<std::vector<std::variant<std::string, double, int64_t, bool, std::shared_ptr<ArrayBuffer>>>>>& value) {
274
- return std::optional<std::variant<std::vector<std::variant<std::string, double, int64_t, bool, std::shared_ptr<ArrayBuffer>>>, std::vector<std::vector<std::variant<std::string, double, int64_t, bool, std::shared_ptr<ArrayBuffer>>>>>>(value);
275
- }
276
-
277
- /**
278
- * Specialized version of `std::vector<BatchQueryCommand>`.
279
- */
280
- using std__vector_BatchQueryCommand_ = std::vector<BatchQueryCommand>;
281
- inline std::vector<BatchQueryCommand> create_std__vector_BatchQueryCommand_(size_t size) {
282
- std::vector<BatchQueryCommand> vector;
283
- vector.reserve(size);
284
- return vector;
285
- }
286
-
287
- /**
288
- * Specialized version of `PromiseHolder<BatchQueryResult>`.
289
- */
290
- using PromiseHolder_BatchQueryResult_ = PromiseHolder<BatchQueryResult>;
291
- inline PromiseHolder<BatchQueryResult> create_PromiseHolder_BatchQueryResult_() {
292
- return PromiseHolder<BatchQueryResult>();
293
- }
294
25
 
295
- /**
296
- * Specialized version of `PromiseHolder<FileLoadResult>`.
297
- */
298
- using PromiseHolder_FileLoadResult_ = PromiseHolder<FileLoadResult>;
299
- inline PromiseHolder<FileLoadResult> create_PromiseHolder_FileLoadResult_() {
300
- return PromiseHolder<FileLoadResult>();
301
- }
302
26
 
303
27
  } // namespace margelo::nitro::rnnitrosqlite::bridge::swift
@@ -8,39 +8,10 @@
8
8
  #pragma once
9
9
 
10
10
  // Forward declarations of C++ defined types
11
- // Forward declaration of `ArrayBuffer` to properly resolve imports.
12
- namespace NitroModules { class ArrayBuffer; }
13
- // Forward declaration of `BatchQueryCommand` to properly resolve imports.
14
- namespace margelo::nitro::rnnitrosqlite { struct BatchQueryCommand; }
15
- // Forward declaration of `BatchQueryResult` to properly resolve imports.
16
- namespace margelo::nitro::rnnitrosqlite { struct BatchQueryResult; }
17
- // Forward declaration of `ColumnType` to properly resolve imports.
18
- namespace margelo::nitro::rnnitrosqlite { enum class ColumnType; }
19
- // Forward declaration of `FileLoadResult` to properly resolve imports.
20
- namespace margelo::nitro::rnnitrosqlite { struct FileLoadResult; }
21
- // Forward declaration of `HybridNativeQueryResultSpec` to properly resolve imports.
22
- namespace margelo::nitro::rnnitrosqlite { class HybridNativeQueryResultSpec; }
23
- // Forward declaration of `HybridNitroSQLiteSpec` to properly resolve imports.
24
- namespace margelo::nitro::rnnitrosqlite { class HybridNitroSQLiteSpec; }
25
- // Forward declaration of `SQLiteQueryColumnMetadata` to properly resolve imports.
26
- namespace margelo::nitro::rnnitrosqlite { struct SQLiteQueryColumnMetadata; }
11
+
27
12
 
28
13
  // Include C++ defined types
29
- #include "BatchQueryCommand.hpp"
30
- #include "BatchQueryResult.hpp"
31
- #include "ColumnType.hpp"
32
- #include "FileLoadResult.hpp"
33
- #include "HybridNativeQueryResultSpec.hpp"
34
- #include "HybridNitroSQLiteSpec.hpp"
35
- #include "SQLiteQueryColumnMetadata.hpp"
36
- #include <NitroModules/ArrayBuffer.hpp>
37
- #include <future>
38
- #include <memory>
39
- #include <optional>
40
- #include <string>
41
- #include <unordered_map>
42
- #include <variant>
43
- #include <vector>
14
+
44
15
 
45
16
  // C++ helpers for Swift
46
17
  #include "RNNitroSQLite-Swift-Cxx-Bridge.hpp"
@@ -52,10 +23,7 @@ namespace margelo::nitro::rnnitrosqlite { struct SQLiteQueryColumnMetadata; }
52
23
  #include <NitroModules/PromiseHolder.hpp>
53
24
 
54
25
  // Forward declarations of Swift defined types
55
- // Forward declaration of `HybridNativeQueryResultSpecCxx` to properly resolve imports.
56
- namespace RNNitroSQLite { class HybridNativeQueryResultSpecCxx; }
57
- // Forward declaration of `HybridNitroSQLiteSpecCxx` to properly resolve imports.
58
- namespace RNNitroSQLite { class HybridNitroSQLiteSpecCxx; }
26
+
59
27
 
60
28
  // Include Swift defined types
61
29
  #if __has_include("RNNitroSQLite-Swift.h")
@@ -6,5 +6,7 @@
6
6
  ///
7
7
 
8
8
  public final class RNNitroSQLiteAutolinking {
9
+ public typealias bridge = margelo.nitro.rnnitrosqlite.bridge.swift
10
+
9
11
 
10
12
  }