@capacitor-community/sqlite 7.0.3 → 8.0.1-dev.ba086e1.1773819779
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.
- package/CapacitorCommunitySqlite.podspec +1 -1
- package/Package.swift +32 -0
- package/README.md +4 -4
- package/android/build.gradle +10 -10
- package/android/src/main/java/com/getcapacitor/community/database/sqlite/CapacitorSQLitePlugin.java +44 -49
- package/android/src/main/java/com/getcapacitor/community/database/sqlite/NotificationCenter.java +1 -1
- package/android/src/main/java/com/getcapacitor/community/database/sqlite/SQLite/ImportExportJson/ImportFromJson.java +1 -1
- package/android/src/main/java/com/getcapacitor/community/database/sqlite/SQLite/UtilsDelete.java +1 -1
- package/android/src/main/java/com/getcapacitor/community/database/sqlite/SQLite/UtilsDrop.java +1 -1
- package/android/src/main/java/com/getcapacitor/community/database/sqlite/SQLite/UtilsSQLStatement.java +2 -2
- package/dist/esm/definitions.js.map +1 -1
- package/dist/esm/web.js.map +1 -1
- package/dist/plugin.cjs.js.map +1 -1
- package/dist/plugin.js.map +1 -1
- package/electron/dist/plugin.js +21 -21
- package/electron/dist/plugin.js.map +1 -1
- package/electron/tsconfig.json +18 -18
- package/ios/Plugin/CapacitorSQLitePlugin.swift +54 -1
- package/package.json +22 -19
- package/ios/Plugin/CapacitorSQLitePlugin.h +0 -10
- package/ios/Plugin/CapacitorSQLitePlugin.m +0 -56
package/electron/tsconfig.json
CHANGED
|
@@ -1,19 +1,19 @@
|
|
|
1
1
|
{
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
}
|
|
2
|
+
"compilerOptions": {
|
|
3
|
+
"allowSyntheticDefaultImports": true,
|
|
4
|
+
"declaration": true,
|
|
5
|
+
"experimentalDecorators": true,
|
|
6
|
+
"noEmitHelpers": true,
|
|
7
|
+
"importHelpers": true,
|
|
8
|
+
"lib": ["dom", "esnext"],
|
|
9
|
+
"module": "commonjs",
|
|
10
|
+
"noImplicitAny": true,
|
|
11
|
+
"noUnusedLocals": true,
|
|
12
|
+
"noUnusedParameters": true,
|
|
13
|
+
"outDir": "build",
|
|
14
|
+
"sourceMap": true,
|
|
15
|
+
"strict": false,
|
|
16
|
+
"target": "ES2020"
|
|
17
|
+
},
|
|
18
|
+
"include": ["src/**/*"]
|
|
19
|
+
}
|
|
@@ -4,7 +4,60 @@ import Capacitor
|
|
|
4
4
|
@objc(CapacitorSQLitePlugin)
|
|
5
5
|
// swiftlint:disable file_length
|
|
6
6
|
// swiftlint:disable type_body_length
|
|
7
|
-
public class CapacitorSQLitePlugin: CAPPlugin {
|
|
7
|
+
public class CapacitorSQLitePlugin: CAPPlugin, CAPBridgedPlugin {
|
|
8
|
+
public let identifier = "CapacitorSQLitePlugin"
|
|
9
|
+
public let jsName = "CapacitorSQLite"
|
|
10
|
+
public let pluginMethods: [CAPPluginMethod] = [
|
|
11
|
+
CAPPluginMethod(name: "echo", returnType: CAPPluginReturnPromise),
|
|
12
|
+
CAPPluginMethod(name: "createConnection", returnType: CAPPluginReturnPromise),
|
|
13
|
+
CAPPluginMethod(name: "closeConnection", returnType: CAPPluginReturnPromise),
|
|
14
|
+
CAPPluginMethod(name: "createNCConnection", returnType: CAPPluginReturnPromise),
|
|
15
|
+
CAPPluginMethod(name: "closeNCConnection", returnType: CAPPluginReturnPromise),
|
|
16
|
+
CAPPluginMethod(name: "getNCDatabasePath", returnType: CAPPluginReturnPromise),
|
|
17
|
+
CAPPluginMethod(name: "open", returnType: CAPPluginReturnPromise),
|
|
18
|
+
CAPPluginMethod(name: "close", returnType: CAPPluginReturnPromise),
|
|
19
|
+
CAPPluginMethod(name: "getUrl", returnType: CAPPluginReturnPromise),
|
|
20
|
+
CAPPluginMethod(name: "getVersion", returnType: CAPPluginReturnPromise),
|
|
21
|
+
CAPPluginMethod(name: "execute", returnType: CAPPluginReturnPromise),
|
|
22
|
+
CAPPluginMethod(name: "executeSet", returnType: CAPPluginReturnPromise),
|
|
23
|
+
CAPPluginMethod(name: "run", returnType: CAPPluginReturnPromise),
|
|
24
|
+
CAPPluginMethod(name: "query", returnType: CAPPluginReturnPromise),
|
|
25
|
+
CAPPluginMethod(name: "isDBExists", returnType: CAPPluginReturnPromise),
|
|
26
|
+
CAPPluginMethod(name: "isDBOpen", returnType: CAPPluginReturnPromise),
|
|
27
|
+
CAPPluginMethod(name: "deleteDatabase", returnType: CAPPluginReturnPromise),
|
|
28
|
+
CAPPluginMethod(name: "importFromJson", returnType: CAPPluginReturnPromise),
|
|
29
|
+
CAPPluginMethod(name: "isJsonValid", returnType: CAPPluginReturnPromise),
|
|
30
|
+
CAPPluginMethod(name: "exportToJson", returnType: CAPPluginReturnPromise),
|
|
31
|
+
CAPPluginMethod(name: "deleteExportedRows", returnType: CAPPluginReturnPromise),
|
|
32
|
+
CAPPluginMethod(name: "createSyncTable", returnType: CAPPluginReturnPromise),
|
|
33
|
+
CAPPluginMethod(name: "setSyncDate", returnType: CAPPluginReturnPromise),
|
|
34
|
+
CAPPluginMethod(name: "getSyncDate", returnType: CAPPluginReturnPromise),
|
|
35
|
+
CAPPluginMethod(name: "addUpgradeStatement", returnType: CAPPluginReturnPromise),
|
|
36
|
+
CAPPluginMethod(name: "copyFromAssets", returnType: CAPPluginReturnPromise),
|
|
37
|
+
CAPPluginMethod(name: "isDatabase", returnType: CAPPluginReturnPromise),
|
|
38
|
+
CAPPluginMethod(name: "isNCDatabase", returnType: CAPPluginReturnPromise),
|
|
39
|
+
CAPPluginMethod(name: "isTableExists", returnType: CAPPluginReturnPromise),
|
|
40
|
+
CAPPluginMethod(name: "getDatabaseList", returnType: CAPPluginReturnPromise),
|
|
41
|
+
CAPPluginMethod(name: "getTableList", returnType: CAPPluginReturnPromise),
|
|
42
|
+
CAPPluginMethod(name: "getMigratableDbList", returnType: CAPPluginReturnPromise),
|
|
43
|
+
CAPPluginMethod(name: "addSQLiteSuffix", returnType: CAPPluginReturnPromise),
|
|
44
|
+
CAPPluginMethod(name: "deleteOldDatabases", returnType: CAPPluginReturnPromise),
|
|
45
|
+
CAPPluginMethod(name: "moveDatabasesAndAddSuffix", returnType: CAPPluginReturnPromise),
|
|
46
|
+
CAPPluginMethod(name: "checkConnectionsConsistency", returnType: CAPPluginReturnPromise),
|
|
47
|
+
CAPPluginMethod(name: "isSecretStored", returnType: CAPPluginReturnPromise),
|
|
48
|
+
CAPPluginMethod(name: "setEncryptionSecret", returnType: CAPPluginReturnPromise),
|
|
49
|
+
CAPPluginMethod(name: "changeEncryptionSecret", returnType: CAPPluginReturnPromise),
|
|
50
|
+
CAPPluginMethod(name: "clearEncryptionSecret", returnType: CAPPluginReturnPromise),
|
|
51
|
+
CAPPluginMethod(name: "getFromHTTPRequest", returnType: CAPPluginReturnPromise),
|
|
52
|
+
CAPPluginMethod(name: "checkEncryptionSecret", returnType: CAPPluginReturnPromise),
|
|
53
|
+
CAPPluginMethod(name: "isInConfigEncryption", returnType: CAPPluginReturnPromise),
|
|
54
|
+
CAPPluginMethod(name: "isInConfigBiometricAuth", returnType: CAPPluginReturnPromise),
|
|
55
|
+
CAPPluginMethod(name: "isDatabaseEncrypted", returnType: CAPPluginReturnPromise),
|
|
56
|
+
CAPPluginMethod(name: "beginTransaction", returnType: CAPPluginReturnPromise),
|
|
57
|
+
CAPPluginMethod(name: "commitTransaction", returnType: CAPPluginReturnPromise),
|
|
58
|
+
CAPPluginMethod(name: "rollbackTransaction", returnType: CAPPluginReturnPromise),
|
|
59
|
+
CAPPluginMethod(name: "isTransactionActive", returnType: CAPPluginReturnPromise)
|
|
60
|
+
]
|
|
8
61
|
private var implementation: CapacitorSQLite?
|
|
9
62
|
private let modeList: [String] = ["no-encryption", "encryption", "secret",
|
|
10
63
|
"decryption", "newsecret", "wrongsecret"]
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@capacitor-community/sqlite",
|
|
3
|
-
"version": "
|
|
3
|
+
"version": "8.0.1-dev.ba086e1.1773819779",
|
|
4
4
|
"description": "Community plugin for native & electron SQLite databases",
|
|
5
5
|
"main": "dist/plugin.cjs.js",
|
|
6
6
|
"module": "dist/esm/index.js",
|
|
@@ -13,7 +13,8 @@
|
|
|
13
13
|
"src/",
|
|
14
14
|
"ios/Plugin/",
|
|
15
15
|
"electron/",
|
|
16
|
-
"CapacitorCommunitySqlite.podspec"
|
|
16
|
+
"CapacitorCommunitySqlite.podspec",
|
|
17
|
+
"Package.swift"
|
|
17
18
|
],
|
|
18
19
|
"author": "Robin Genz <mail@robingenz.dev>",
|
|
19
20
|
"license": "MIT",
|
|
@@ -57,30 +58,32 @@
|
|
|
57
58
|
"watch": "tsc --watch",
|
|
58
59
|
"test": "echo \"No test specified\"",
|
|
59
60
|
"prepublishOnly": "npm run build && npm run build-electron && npm run docgen",
|
|
60
|
-
"release": "commit-and-tag-version"
|
|
61
|
+
"release": "commit-and-tag-version",
|
|
62
|
+
"ios:spm:install": "cd ios && swift package resolve && cd .."
|
|
61
63
|
},
|
|
62
64
|
"devDependencies": {
|
|
63
|
-
"@capacitor/android": "
|
|
64
|
-
"@capacitor/cli": "
|
|
65
|
-
"@capacitor/core": "
|
|
66
|
-
"@capacitor/docgen": "0.3.
|
|
67
|
-
"@capacitor/ios": "
|
|
68
|
-
"@ionic/eslint-config": "0.4.0",
|
|
69
|
-
"@ionic/prettier-config": "4.0.0",
|
|
70
|
-
"@ionic/swiftlint-config": "2.0.0",
|
|
65
|
+
"@capacitor/android": "^8.0.0",
|
|
66
|
+
"@capacitor/cli": "^8.0.0",
|
|
67
|
+
"@capacitor/core": "^8.0.0",
|
|
68
|
+
"@capacitor/docgen": "^0.3.1",
|
|
69
|
+
"@capacitor/ios": "^8.0.0",
|
|
70
|
+
"@ionic/eslint-config": "^0.4.0",
|
|
71
|
+
"@ionic/prettier-config": "^4.0.0",
|
|
72
|
+
"@ionic/swiftlint-config": "^2.0.0",
|
|
71
73
|
"@rollup/plugin-commonjs": "28.0.2",
|
|
72
74
|
"@rollup/plugin-node-resolve": "16.0.0",
|
|
75
|
+
"@types/node": "25.0.3",
|
|
73
76
|
"commit-and-tag-version": "12.6.1",
|
|
74
|
-
"eslint": "8.57.
|
|
75
|
-
"prettier": "3.
|
|
76
|
-
"prettier-plugin-java": "2.
|
|
77
|
-
"rimraf": "6.0
|
|
78
|
-
"rollup": "4.
|
|
79
|
-
"swiftlint": "2.0.0",
|
|
80
|
-
"typescript": "
|
|
77
|
+
"eslint": "^8.57.1",
|
|
78
|
+
"prettier": "^3.6.2",
|
|
79
|
+
"prettier-plugin-java": "^2.7.7",
|
|
80
|
+
"rimraf": "^6.1.0",
|
|
81
|
+
"rollup": "^4.53.2",
|
|
82
|
+
"swiftlint": "^2.0.0",
|
|
83
|
+
"typescript": "^5.9.3"
|
|
81
84
|
},
|
|
82
85
|
"peerDependencies": {
|
|
83
|
-
"@capacitor/core": ">=
|
|
86
|
+
"@capacitor/core": ">=8.0.0"
|
|
84
87
|
},
|
|
85
88
|
"prettier": "@ionic/prettier-config",
|
|
86
89
|
"swiftlint": "@ionic/swiftlint-config",
|
|
@@ -1,10 +0,0 @@
|
|
|
1
|
-
#import <UIKit/UIKit.h>
|
|
2
|
-
|
|
3
|
-
//! Project version number for Plugin.
|
|
4
|
-
FOUNDATION_EXPORT double PluginVersionNumber;
|
|
5
|
-
|
|
6
|
-
//! Project version string for Plugin.
|
|
7
|
-
FOUNDATION_EXPORT const unsigned char PluginVersionString[];
|
|
8
|
-
|
|
9
|
-
// In this header, you should import all the public headers of your framework using statements like #import <Plugin/PublicHeader.h>
|
|
10
|
-
|
|
@@ -1,56 +0,0 @@
|
|
|
1
|
-
#import <Foundation/Foundation.h>
|
|
2
|
-
#import <Capacitor/Capacitor.h>
|
|
3
|
-
|
|
4
|
-
// Define the plugin using the CAP_PLUGIN Macro, and
|
|
5
|
-
// each method the plugin supports using the CAP_PLUGIN_METHOD macro.
|
|
6
|
-
CAP_PLUGIN(CapacitorSQLitePlugin, "CapacitorSQLite",
|
|
7
|
-
CAP_PLUGIN_METHOD(echo, CAPPluginReturnPromise);
|
|
8
|
-
CAP_PLUGIN_METHOD(createConnection, CAPPluginReturnPromise);
|
|
9
|
-
CAP_PLUGIN_METHOD(closeConnection, CAPPluginReturnPromise);
|
|
10
|
-
CAP_PLUGIN_METHOD(createNCConnection, CAPPluginReturnPromise);
|
|
11
|
-
CAP_PLUGIN_METHOD(closeNCConnection, CAPPluginReturnPromise);
|
|
12
|
-
CAP_PLUGIN_METHOD(getNCDatabasePath, CAPPluginReturnPromise);
|
|
13
|
-
CAP_PLUGIN_METHOD(open, CAPPluginReturnPromise);
|
|
14
|
-
CAP_PLUGIN_METHOD(close, CAPPluginReturnPromise);
|
|
15
|
-
CAP_PLUGIN_METHOD(getUrl, CAPPluginReturnPromise);
|
|
16
|
-
CAP_PLUGIN_METHOD(getVersion, CAPPluginReturnPromise);
|
|
17
|
-
CAP_PLUGIN_METHOD(execute, CAPPluginReturnPromise);
|
|
18
|
-
CAP_PLUGIN_METHOD(executeSet, CAPPluginReturnPromise);
|
|
19
|
-
CAP_PLUGIN_METHOD(run, CAPPluginReturnPromise);
|
|
20
|
-
CAP_PLUGIN_METHOD(query, CAPPluginReturnPromise);
|
|
21
|
-
CAP_PLUGIN_METHOD(isDBExists, CAPPluginReturnPromise);
|
|
22
|
-
CAP_PLUGIN_METHOD(isDBOpen, CAPPluginReturnPromise);
|
|
23
|
-
CAP_PLUGIN_METHOD(deleteDatabase, CAPPluginReturnPromise);
|
|
24
|
-
CAP_PLUGIN_METHOD(importFromJson, CAPPluginReturnPromise);
|
|
25
|
-
CAP_PLUGIN_METHOD(isJsonValid, CAPPluginReturnPromise);
|
|
26
|
-
CAP_PLUGIN_METHOD(exportToJson, CAPPluginReturnPromise);
|
|
27
|
-
CAP_PLUGIN_METHOD(deleteExportedRows, CAPPluginReturnPromise);
|
|
28
|
-
CAP_PLUGIN_METHOD(createSyncTable, CAPPluginReturnPromise);
|
|
29
|
-
CAP_PLUGIN_METHOD(setSyncDate, CAPPluginReturnPromise);
|
|
30
|
-
CAP_PLUGIN_METHOD(getSyncDate, CAPPluginReturnPromise);
|
|
31
|
-
CAP_PLUGIN_METHOD(addUpgradeStatement, CAPPluginReturnPromise);
|
|
32
|
-
CAP_PLUGIN_METHOD(copyFromAssets, CAPPluginReturnPromise);
|
|
33
|
-
CAP_PLUGIN_METHOD(isDatabase, CAPPluginReturnPromise);
|
|
34
|
-
CAP_PLUGIN_METHOD(isNCDatabase, CAPPluginReturnPromise);
|
|
35
|
-
CAP_PLUGIN_METHOD(isTableExists, CAPPluginReturnPromise);
|
|
36
|
-
CAP_PLUGIN_METHOD(getDatabaseList, CAPPluginReturnPromise);
|
|
37
|
-
CAP_PLUGIN_METHOD(getTableList, CAPPluginReturnPromise);
|
|
38
|
-
CAP_PLUGIN_METHOD(getMigratableDbList, CAPPluginReturnPromise);
|
|
39
|
-
CAP_PLUGIN_METHOD(addSQLiteSuffix, CAPPluginReturnPromise);
|
|
40
|
-
CAP_PLUGIN_METHOD(deleteOldDatabases, CAPPluginReturnPromise);
|
|
41
|
-
CAP_PLUGIN_METHOD(moveDatabasesAndAddSuffix, CAPPluginReturnPromise);
|
|
42
|
-
CAP_PLUGIN_METHOD(checkConnectionsConsistency, CAPPluginReturnPromise);
|
|
43
|
-
CAP_PLUGIN_METHOD(isSecretStored, CAPPluginReturnPromise);
|
|
44
|
-
CAP_PLUGIN_METHOD(setEncryptionSecret, CAPPluginReturnPromise);
|
|
45
|
-
CAP_PLUGIN_METHOD(changeEncryptionSecret, CAPPluginReturnPromise);
|
|
46
|
-
CAP_PLUGIN_METHOD(clearEncryptionSecret, CAPPluginReturnPromise);
|
|
47
|
-
CAP_PLUGIN_METHOD(getFromHTTPRequest, CAPPluginReturnPromise);
|
|
48
|
-
CAP_PLUGIN_METHOD(checkEncryptionSecret, CAPPluginReturnPromise);
|
|
49
|
-
CAP_PLUGIN_METHOD(isInConfigEncryption, CAPPluginReturnPromise);
|
|
50
|
-
CAP_PLUGIN_METHOD(isInConfigBiometricAuth, CAPPluginReturnPromise);
|
|
51
|
-
CAP_PLUGIN_METHOD(isDatabaseEncrypted, CAPPluginReturnPromise);
|
|
52
|
-
CAP_PLUGIN_METHOD(beginTransaction, CAPPluginReturnPromise);
|
|
53
|
-
CAP_PLUGIN_METHOD(commitTransaction, CAPPluginReturnPromise);
|
|
54
|
-
CAP_PLUGIN_METHOD(rollbackTransaction, CAPPluginReturnPromise);
|
|
55
|
-
CAP_PLUGIN_METHOD(isTransactionActive, CAPPluginReturnPromise);
|
|
56
|
-
)
|