cordova-sqlite-evmax-build-free 0.0.11 → 0.1.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.
- package/CHANGES.md +16 -0
- package/README.md +8 -6
- package/SQLitePlugin.coffee.md +6 -0
- package/package.json +1 -1
- package/plugin.xml +4 -13
- package/spec/www/spec/sqlite-version-test.js +1 -1
- package/src/android/io/sqlc/SQLitePlugin.java +7 -5
- package/src/deps/android/sqlc-evmax-ndk-driver.jar +0 -0
- package/src/deps/common/sqlite3.c +27127 -11983
- package/src/deps/common/sqlite3.h +1175 -327
- package/www/SQLitePlugin.js +4 -0
- package/spec/ca.sh +0 -113
- package/src/windows/libs/dummy/BarcodeComponent.winmd +0 -0
- package/src/windows/libs/x64/SQLite3.UWP.dll +0 -0
- package/src/windows/libs/x64/SQLite3.winmd +0 -0
- package/src/windows/libs/x86/SQLite3.UWP.dll +0 -0
- package/src/windows/libs/x86/SQLite3.winmd +0 -0
package/CHANGES.md
CHANGED
|
@@ -1,5 +1,21 @@
|
|
|
1
1
|
# Changes
|
|
2
2
|
|
|
3
|
+
# cordova-sqlite-evmax-build-free 0.1.0
|
|
4
|
+
|
|
5
|
+
## cordova-sqlite-evmax-feat-android-db-location 0.0.3-dev
|
|
6
|
+
|
|
7
|
+
## cordova-sqlite-evmax-common-free 0.0.8-dev
|
|
8
|
+
|
|
9
|
+
- more robust handling of large results on Android - replace PluginResult.setKeepCallback() usage to avoid potential stability issue described in:
|
|
10
|
+
- https://github.com/storesafe/cordova-plugin-sqlite-evplus-ext-common-free/issues/14
|
|
11
|
+
|
|
12
|
+
NOTE: While this may introduce a little more overhead, this overhead is expected to be very minor relative to the cost of handling large results between the C, Java, and JavaScript code.
|
|
13
|
+
|
|
14
|
+
# cordova-sqlite-evmax-build-free 0.0.12
|
|
15
|
+
|
|
16
|
+
- update SQLite -> 3.51.2
|
|
17
|
+
- disable support for macOS ("OSX") & Windows (deprecated Cordova platforms)
|
|
18
|
+
|
|
3
19
|
# cordova-sqlite-evmax-build-free 0.0.11
|
|
4
20
|
|
|
5
21
|
- rebuild JAR with JDK 17, as needed by many build systems with Gradle 8
|
package/README.md
CHANGED
|
@@ -3,8 +3,10 @@
|
|
|
3
3
|
Native SQLite component with API based on HTML5/[Web SQL (DRAFT) API](http://www.w3.org/TR/webdatabase/) for the following platforms:
|
|
4
4
|
- Android
|
|
5
5
|
- iOS
|
|
6
|
-
- macOS ("osx" platform)
|
|
7
|
-
- Windows 10 (UWP) DESKTOP
|
|
6
|
+
- ~~macOS ("osx" platform)~~
|
|
7
|
+
- ~~Windows 10 (UWP) DESKTOP and MOBILE (see below for major limitations)~~
|
|
8
|
+
|
|
9
|
+
NOTICE: DEPRECATED Cordova OSX & WINDOWS PLATFORMS ARE NO LONGER SUPPORTED BY THIS PLUGIN VERSION
|
|
8
10
|
|
|
9
11
|
<!-- [TBD] HIDE browser usage notes for now (at least):
|
|
10
12
|
Browser platform is currently supported with some limitations as described in [browser platform usage notes](#browser-platform-usage-notes) section below, will be supported with more features such as numbered parameters and SQL batch API in the near future.
|
|
@@ -52,7 +54,7 @@ under consideration:
|
|
|
52
54
|
|
|
53
55
|
## About this plugin version
|
|
54
56
|
|
|
55
|
-
Super-premium enterprise version with additional performance and stability improvements for Android, iOS, and macOS
|
|
57
|
+
Super-premium enterprise version with additional performance and stability improvements for Android, iOS, ~~and macOS,~~ including workarounds for super-large INSERT transactions and SELECT results on Android - with limited extra features (missing pre-populated database support), using the `before_plugin_install` hook to fetch the sqlite3 component dependencies from <https://github.com/brodybits/cordova-sqlite-evmax-free-dependencies-dev>.
|
|
56
58
|
|
|
57
59
|
<!-- FUTURE TBD critical bug notices for this plugin version -->
|
|
58
60
|
|
|
@@ -200,8 +202,8 @@ See the [Sample section](#sample) for a sample with a more detailed explanation
|
|
|
200
202
|
- Cordova versions older than `6.0.0` are missing the `cordova-ios@4.0.0` security fixes.
|
|
201
203
|
- This plugin version includes the following extra (non-standard) features:
|
|
202
204
|
- BASE64 and BLOBFROMBASE64 integrated from [brodybits / sqlite3-base64](https://github.com/brodybits/sqlite3-base64), using [brodybits / libb64-core](https://github.com/brodybits/libb64-core) (based on <http://libb64.sourceforge.net/> by Chris Venter, public domain)
|
|
203
|
-
- REGEXP for Android (default Android-sqlite-connector database implementation), iOS, and macOS using [brodybits / sqlite3-regexp-cached](https://github.com/brodybits/sqlite3-regexp-cached) (based on <http://git.altlinux.org/people/at/packages/?p=sqlite3-pcre.git> by Alexey Tourbin, public domain)
|
|
204
|
-
- SQLite __`3.
|
|
205
|
+
- REGEXP for Android (default Android-sqlite-connector database implementation), iOS, ~~and macOS~~ using [brodybits / sqlite3-regexp-cached](https://github.com/brodybits/sqlite3-regexp-cached) (based on <http://git.altlinux.org/people/at/packages/?p=sqlite3-pcre.git> by Alexey Tourbin, public domain)
|
|
206
|
+
- SQLite __`3.51.2`__ included when building (all platforms), with the following compile-time definitions:
|
|
205
207
|
- `SQLITE_THREADSAFE=1`
|
|
206
208
|
- `SQLITE_DEFAULT_SYNCHRONOUS=3` (EXTRA DURABLE build setting) ref: [xpbrew/cordova-sqlite-storage#736](https://github.com/xpbrew/cordova-sqlite-storage/issues/736)
|
|
207
209
|
- `SQLITE_LOCKING_STYLE=1` on iOS/macOS ONLY
|
|
@@ -282,7 +284,7 @@ See the [Sample section](#sample) for a sample with a more detailed explanation
|
|
|
282
284
|
- This plugin version now supports SELECT BLOB data in Base64 format on all platforms in addition to REGEXP (Android/iOS/macOS) ~~and pre-populated database (all platforms - FUTURE TODO)~~.
|
|
283
285
|
- [brodybits / sql-promise-helper](https://github.com/brodybits/sql-promise-helper) provides a Promise-based API wrapper.
|
|
284
286
|
- _[`pouchdb-adapter-cordova-sqlite`](https://github.com/nolanlawson/pouchdb-adapter-cordova-sqlite) supports this plugin along with other implementations such as [nolanlawson / sqlite-plugin-2](https://github.com/nolanlawson/sqlite-plugin-2) and [Microsoft / cordova-plugin-websql](https://github.com/Microsoft/cordova-plugin-websql)._
|
|
285
|
-
- macOS ("osx" platform) is now supported
|
|
287
|
+
- ~~macOS ("osx" platform) is now supported~~
|
|
286
288
|
- Published [brodybits / Cordova-quick-start-checklist](https://github.com/brodybits/Cordova-quick-start-checklist) and [brodybits / Avoiding-some-Cordova-pitfalls](https://github.com/brodybits/Avoiding-some-Cordova-pitfalls).
|
|
287
289
|
- Self-test functions to verify proper installation and operation of this plugin
|
|
288
290
|
- More explicit `openDatabase` and `deleteDatabase` `iosDatabaseLocation` option
|
package/SQLitePlugin.coffee.md
CHANGED
|
@@ -721,10 +721,16 @@
|
|
|
721
721
|
cb1 = (result) ->
|
|
722
722
|
if result[0] is 'multi'
|
|
723
723
|
ch1 = true
|
|
724
|
+
# trigger next callback from Java side
|
|
725
|
+
# (using "fjnext:..." rather than "fj:..." for the sake of clarity)
|
|
726
|
+
cordova.exec cb1, null, "SQLitePlugin", "fjnext:0;extra", [mydbid, 0]
|
|
724
727
|
else if result[0] isnt null
|
|
725
728
|
resultSet = resultSet.concat result.slice(0, result.length-1)
|
|
726
729
|
if !ch1
|
|
727
730
|
cb1 [null]
|
|
731
|
+
if ch1
|
|
732
|
+
# trigger next callback from Java side (see comment above regarding "fjnext:")
|
|
733
|
+
cordova.exec cb1, null, "SQLitePlugin", "fjnext:0;extra", [mydbid, 0]
|
|
728
734
|
else # if result[0] is null
|
|
729
735
|
if (index + 1 == batchExecutesLength)
|
|
730
736
|
cb resultSet
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "cordova-sqlite-evmax-build-free",
|
|
3
|
-
"version": "0.0
|
|
3
|
+
"version": "0.1.0",
|
|
4
4
|
"description": "Cordova/PhoneGap sqlite storage - free evmax enterprise version with premium stability and performance improvements including workaround for super-large INSERT transactions & SELECT results on Android (version with external sqlite3 dependencies)",
|
|
5
5
|
"cordova": {
|
|
6
6
|
"id": "cordova-sqlite-evmax-build-free",
|
package/plugin.xml
CHANGED
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
<plugin xmlns="http://www.phonegap.com/ns/plugins/1.0"
|
|
3
3
|
xmlns:android="http://schemas.android.com/apk/res/android"
|
|
4
4
|
id="cordova-sqlite-evmax-build-free"
|
|
5
|
-
version="0.0
|
|
5
|
+
version="0.1.0">
|
|
6
6
|
|
|
7
7
|
<name>Cordova sqlite storage - free evmax common version branch with premium stability performance improvements including workaround for super-large INSERT transactions and SELECT results on Android (with external sqlite3 dependencies)</name>
|
|
8
8
|
|
|
@@ -70,7 +70,7 @@
|
|
|
70
70
|
</platform>
|
|
71
71
|
|
|
72
72
|
<!-- macOS (osx) -->
|
|
73
|
-
<platform name="osx">
|
|
73
|
+
<platform name="disabled-osx">
|
|
74
74
|
<config-file target="config.xml" parent="/*">
|
|
75
75
|
<feature name="SQLitePlugin">
|
|
76
76
|
<param name="osx-package" value="SQLitePlugin" />
|
|
@@ -103,7 +103,7 @@
|
|
|
103
103
|
</platform>
|
|
104
104
|
|
|
105
105
|
<!-- windows -->
|
|
106
|
-
<platform name="windows">
|
|
106
|
+
<platform name="disabled-windows">
|
|
107
107
|
<js-module src="src/windows/sqlite-proxy.js" name="SQLiteProxy">
|
|
108
108
|
<runs />
|
|
109
109
|
</js-module>
|
|
@@ -114,18 +114,9 @@
|
|
|
114
114
|
</js-module>
|
|
115
115
|
|
|
116
116
|
<!-- Thanks to AllJoyn-Cordova / cordova-plugin-alljoyn for guidance: -->
|
|
117
|
-
<!-- uncomment next line to
|
|
117
|
+
<!-- uncomment next line to build WinMD & DLL artifacts - Release build is required:
|
|
118
118
|
<framework src="src/windows/SQLite3-WinRT-sync/SQLite3/SQLite3.UWP.vcxproj" custom="true" type="projectReference" versions="10.*" />
|
|
119
119
|
-->
|
|
120
|
-
<!-- remove these when rebuilding WinMD & DLL artifacts -->
|
|
121
|
-
<!-- sources:
|
|
122
|
-
- https://www.dynamsoft.com/codepool/cordova-plugin-barcode-winrt.html
|
|
123
|
-
- https://github.com/yushulx/cordova-windows-barcode
|
|
124
|
-
- -->
|
|
125
|
-
<framework src="src/windows/libs/dummy/BarcodeComponent.winmd" target-dir="x86" arch="x86" custom="true"/>
|
|
126
|
-
<framework src="src/windows/libs/x86/SQLite3.winmd" target-dir="x86" arch="x86" custom="true" implementation="src/windows/libs/x86/SQLite3.UWP.dll"/>
|
|
127
|
-
<framework src="src/windows/libs/dummy/BarcodeComponent.winmd" target-dir="x64" arch="x64" custom="true"/>
|
|
128
|
-
<framework src="src/windows/libs/x86/SQLite3.winmd" target-dir="x64" arch="x64" custom="true" implementation="src/windows/libs/x64/SQLite3.UWP.dll"/>
|
|
129
120
|
</platform>
|
|
130
121
|
|
|
131
122
|
</plugin>
|
|
@@ -104,7 +104,7 @@ var mytests = function() {
|
|
|
104
104
|
expect(rs).toBeDefined();
|
|
105
105
|
expect(rs.rows).toBeDefined();
|
|
106
106
|
expect(rs.rows.length).toBe(1);
|
|
107
|
-
expect(rs.rows.item(0).myResult).toBe('3.
|
|
107
|
+
expect(rs.rows.item(0).myResult).toBe('3.51.2');
|
|
108
108
|
|
|
109
109
|
// Close (plugin only) & finish:
|
|
110
110
|
(isWebSql) ? done() : db.close(done, done);
|
|
@@ -61,7 +61,7 @@ public class SQLitePlugin extends CordovaPlugin {
|
|
|
61
61
|
|
|
62
62
|
@Override
|
|
63
63
|
public boolean execute(String actionAsString, String argsAsString, CallbackContext cbc) {
|
|
64
|
-
if (actionAsString.startsWith("fj")) {
|
|
64
|
+
if (actionAsString.startsWith("fj")) { // matches both fj: & fjnext: actions
|
|
65
65
|
int sep1pos = actionAsString.indexOf(':');
|
|
66
66
|
int sep2pos = actionAsString.indexOf(';');
|
|
67
67
|
|
|
@@ -514,10 +514,11 @@ public class SQLitePlugin extends CordovaPlugin {
|
|
|
514
514
|
final String jr1 = EVNDKDriver.sqlc_evplus_qc_execute(qc, dbq.fj);
|
|
515
515
|
final boolean multi = jr1.charAt(2) == 'm';
|
|
516
516
|
final PluginResult pr1 = new MyPluginResult(jr1);
|
|
517
|
+
dbq.cbc.sendPluginResult(pr1);
|
|
517
518
|
if (multi) {
|
|
518
|
-
|
|
519
|
+
// wait for fjnext: action from JavaScript
|
|
520
|
+
dbq = q.take();
|
|
519
521
|
}
|
|
520
|
-
dbq.cbc.sendPluginResult(pr1);
|
|
521
522
|
|
|
522
523
|
boolean more = multi;
|
|
523
524
|
|
|
@@ -525,10 +526,11 @@ public class SQLitePlugin extends CordovaPlugin {
|
|
|
525
526
|
final String jr2 = EVNDKDriver.sqlc_evplus_qc_execute(qc, "");
|
|
526
527
|
more = jr2.charAt(1) != 'n';
|
|
527
528
|
final PluginResult pr2 = new MyPluginResult(jr2);
|
|
529
|
+
dbq.cbc.sendPluginResult(pr2);
|
|
528
530
|
if (more) {
|
|
529
|
-
|
|
531
|
+
// wait for fjnext: action from JavaScript
|
|
532
|
+
dbq = q.take();
|
|
530
533
|
}
|
|
531
|
-
dbq.cbc.sendPluginResult(pr2);
|
|
532
534
|
}
|
|
533
535
|
|
|
534
536
|
// cleanup:
|
|
Binary file
|