Expose sqlite3_stmt_status() to JNI.
FossilOrigin-Name: d266acc23ecb7e76c8c68c6e89a76e6f3054f33f0262e60e06b258db5a5e2ccd
This commit is contained in:
parent
1943356268
commit
286f30f85c
@ -4314,6 +4314,14 @@ S3JniApi(sqlite3_status64(),jint,1status64)(
|
||||
return (jint)rc;
|
||||
}
|
||||
|
||||
S3JniApi(sqlite3_stmt_status(),jint,1stmt_1status)(
|
||||
JniArgsEnvClass, jobject jStmt, jint op, jboolean reset
|
||||
){
|
||||
return sqlite3_stmt_status(PtrGet_sqlite3_stmt(jStmt),
|
||||
(int)op, reset ? 1 : 0);
|
||||
}
|
||||
|
||||
|
||||
static int s3jni_strlike_glob(int isLike, JNIEnv *const env,
|
||||
jbyteArray baG, jbyteArray baT, jint escLike){
|
||||
int rc = 0;
|
||||
|
@ -1803,6 +1803,14 @@ JNIEXPORT jint JNICALL Java_org_sqlite_jni_SQLite3Jni_sqlite3_1stmt_1isexplain
|
||||
JNIEXPORT jboolean JNICALL Java_org_sqlite_jni_SQLite3Jni_sqlite3_1stmt_1readonly
|
||||
(JNIEnv *, jclass, jobject);
|
||||
|
||||
/*
|
||||
* Class: org_sqlite_jni_SQLite3Jni
|
||||
* Method: sqlite3_stmt_status
|
||||
* Signature: (Lorg/sqlite/jni/sqlite3_stmt;IZ)I
|
||||
*/
|
||||
JNIEXPORT jint JNICALL Java_org_sqlite_jni_SQLite3Jni_sqlite3_1stmt_1status
|
||||
(JNIEnv *, jclass, jobject, jint, jboolean);
|
||||
|
||||
/*
|
||||
* Class: org_sqlite_jni_SQLite3Jni
|
||||
* Method: sqlite3_strglob
|
||||
|
@ -1431,6 +1431,11 @@ public final class SQLite3Jni {
|
||||
@Canonical
|
||||
public static native boolean sqlite3_stmt_readonly(@NotNull sqlite3_stmt stmt);
|
||||
|
||||
@Canonical
|
||||
public static native int sqlite3_stmt_status(
|
||||
@NotNull sqlite3_stmt stmt, int op, boolean reset
|
||||
);
|
||||
|
||||
/**
|
||||
Internal impl of the public sqlite3_strglob() method. Neither
|
||||
argument may be null and both must be NUL-terminated UTF-8.
|
||||
|
@ -800,7 +800,7 @@ public class Tester1 implements Runnable {
|
||||
int rc = sqlite3_create_function(db, "myfunc", 1, SQLITE_UTF8, func);
|
||||
affirm(0 == rc);
|
||||
sqlite3_stmt stmt = prepare(db, "select myfunc(a), myfunc(a+10) from t");
|
||||
affirm( null != stmt );
|
||||
affirm( 0==sqlite3_stmt_status(stmt, SQLITE_STMTSTATUS_RUN, false) );
|
||||
int n = 0;
|
||||
if( SQLITE_ROW == sqlite3_step(stmt) ){
|
||||
int v = sqlite3_column_int(stmt, 0);
|
||||
@ -812,6 +812,7 @@ public class Tester1 implements Runnable {
|
||||
affirm( 1==n );
|
||||
affirm(!xFinalNull.value);
|
||||
sqlite3_reset(stmt);
|
||||
affirm( 1==sqlite3_stmt_status(stmt, SQLITE_STMTSTATUS_RUN, false) );
|
||||
// Ensure that the accumulator is reset on subsequent calls...
|
||||
n = 0;
|
||||
if( SQLITE_ROW == sqlite3_step(stmt) ){
|
||||
|
18
manifest
18
manifest
@ -1,5 +1,5 @@
|
||||
C Expose\ssqlite3_randomness()\sto\sJNI.
|
||||
D 2023-09-03T12:17:34.015
|
||||
C Expose\ssqlite3_stmt_status()\sto\sJNI.
|
||||
D 2023-09-03T12:32:09.643
|
||||
F .fossil-settings/empty-dirs dbb81e8fc0401ac46a1491ab34a7f2c7c0452f2f06b54ebb845d024ca8283ef1
|
||||
F .fossil-settings/ignore-glob 35175cdfcf539b2318cb04a9901442804be81cd677d8b889fcc9149c21f239ea
|
||||
F LICENSE.md df5091916dbb40e6e9686186587125e1b2ff51f022cc334e886c19a0e9982724
|
||||
@ -237,8 +237,8 @@ F ext/icu/sqliteicu.h fa373836ed5a1ee7478bdf8a1650689294e41d0c89c1daab26e9ae78a3
|
||||
F ext/jni/GNUmakefile 7bd7f0c28d664b71b08f9d8ff507eb8329f1f3e7b5d88f774f90a1a5259a3fe8
|
||||
F ext/jni/README.md 1332b1fa27918bd5d9ca2d0d4f3ac3a6ab86b9e3699dc5bfe32904a027f3d2a9
|
||||
F ext/jni/jar-dist.make 030aaa4ae71dd86e4ec5e7c1e6cd86f9dfa47c4592c070d2e35157e42498e1fa
|
||||
F ext/jni/src/c/sqlite3-jni.c 0f10efb673d94b2a4b0b76e42cc8951341df6197d8454f08b6db25b1554242c5
|
||||
F ext/jni/src/c/sqlite3-jni.h c3d1fa02f34bd5d2d71c9172be7732e59624cbc3639419ae3929512c18e102dc
|
||||
F ext/jni/src/c/sqlite3-jni.c a9ad3d9d960724eeeb7e93bcef7aa12289e68296f30dd2d77d02f299cac99721
|
||||
F ext/jni/src/c/sqlite3-jni.h 473c4b35d9f5ea9d79ac1b3b0ea00cc78e8e0385d87a4cb6d8ae8f0bcde2351c
|
||||
F ext/jni/src/org/sqlite/jni/AbstractCollationCallback.java 95e88ba04f4aac51ffec65693e878e234088b2f21b387f4e4285c8b72b33e436
|
||||
F ext/jni/src/org/sqlite/jni/AggregateFunction.java 7312486bc65fecdb91753c0a4515799194e031f45edbe16a6373cea18f404dc4
|
||||
F ext/jni/src/org/sqlite/jni/AuthorizerCallback.java e6135be32f12bf140bffa39be7fd1a45ad83b2661ed49c08dbde04c8485feb38
|
||||
@ -262,10 +262,10 @@ F ext/jni/src/org/sqlite/jni/ProgressHandlerCallback.java 7b9ff2218129ece98ba60c
|
||||
F ext/jni/src/org/sqlite/jni/ResultCode.java ba701f20213a5f259e94cfbfdd36eb7ac7ce7797f2c6c7fca2004ff12ce20f86
|
||||
F ext/jni/src/org/sqlite/jni/RollbackHookCallback.java d12352c0e22840de484ffa9b11ed5058bb0daca2e9f218055d3c54c947a273c4
|
||||
F ext/jni/src/org/sqlite/jni/SQLFunction.java 544a875d33fd160467d82e2397ac33157b29971d715a821a4fad3c899113ee8c
|
||||
F ext/jni/src/org/sqlite/jni/SQLite3Jni.java 8ed33203f0958c32571112164d79edd22b00bb0de4c0f5108e1a5ebf2534ce20
|
||||
F ext/jni/src/org/sqlite/jni/SQLite3Jni.java 85e48806781b6c0ebb7f262444b00df2933d6e197181623c7a930c0efb0e1a8b
|
||||
F ext/jni/src/org/sqlite/jni/ScalarFunction.java 6d387bb499fbe3bc13c53315335233dbf6a0c711e8fa7c521683219b041c614c
|
||||
F ext/jni/src/org/sqlite/jni/TableColumnMetadata.java 54511b4297fa28dcb3f49b24035e34ced10e3fd44fd0e458e784f4d6b0096dab
|
||||
F ext/jni/src/org/sqlite/jni/Tester1.java caf32da9a15a1202bdb801a036c233864bf676569143057f83d70b5ba2f44ae5
|
||||
F ext/jni/src/org/sqlite/jni/Tester1.java 14b3a129755a1a19271bdab9de6f4c58898aa28dfe3c03e7f0d23728254dc0d3
|
||||
F ext/jni/src/org/sqlite/jni/TesterFts5.java 1d127690daac4751300b277a14c09faa0cefd1efa365580cd8d95ea658e1ee59
|
||||
F ext/jni/src/org/sqlite/jni/TraceV2Callback.java beb0b064c1a5f8bfe585a324ed39a4e33edbe379a3fc60f1401661620d3ca7c0
|
||||
F ext/jni/src/org/sqlite/jni/UpdateHookCallback.java 8376f4a931f2d5612b295c003c9515ba933ee76d8f95610e89c339727376e36c
|
||||
@ -2117,8 +2117,8 @@ F vsixtest/vsixtest.tcl 6a9a6ab600c25a91a7acc6293828957a386a8a93
|
||||
F vsixtest/vsixtest.vcxproj.data 2ed517e100c66dc455b492e1a33350c1b20fbcdc
|
||||
F vsixtest/vsixtest.vcxproj.filters 37e51ffedcdb064aad6ff33b6148725226cd608e
|
||||
F vsixtest/vsixtest_TemporaryKey.pfx e5b1b036facdb453873e7084e1cae9102ccc67a0
|
||||
P 0de3271717e0298070097d7ea0ecb996d2e95cf65384e494515a554d0a1dffed
|
||||
R 1c9493f53aa49acbc7601207cf3c352b
|
||||
P de9692242132b8f2c92ef4acb08dd3063327b18666cbb17c4f1153dee9146eaf
|
||||
R ebcdf0ddc07ec0bc930ef3346f428207
|
||||
U stephan
|
||||
Z a919ad1706be2f43ac4c9258eceb6670
|
||||
Z 84012132b5e2bcd623d210f7c0541b51
|
||||
# Remove this line to create a well-formed Fossil manifest.
|
||||
|
@ -1 +1 @@
|
||||
de9692242132b8f2c92ef4acb08dd3063327b18666cbb17c4f1153dee9146eaf
|
||||
d266acc23ecb7e76c8c68c6e89a76e6f3054f33f0262e60e06b258db5a5e2ccd
|
Loading…
Reference in New Issue
Block a user