qt5base-lts/tests/auto/corelib
Volker Hilsheimer a085a14d76 Generate JNI signature strings at compile time
Introduce an internal QtJniTypes namespace with types that allow us to
concatenate string literals at compile time. This makes it possible to
generate arbitrary strings based on types, which we can then use as
signatures to JNI method calls.

Move some of the private members of QJniObject into the QtJniTypes
namespace for consistency, and to allow further template specialization
by user code to make other types and their JNI signature string known.
Remove the "Jni" prefix from names.

Use the compile-time generated string in QJniObject methods that created
the signature string at runtime, which involved a temporary memory
allocation.

Treat 'void' as a primitive type (with signature string 'V'), and
remove redundant template specializations.

Add a test case to verify the the strings are constructed correctly
at compile time.

Change-Id: I5e3895a97f7dc1b86961f7a7855b899d9203037d
Reviewed-by: Assam Boudjelthia <assam.boudjelthia@qt.io>
Reviewed-by: Marc Mutz <marc.mutz@qt.io>
Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
2022-05-05 07:29:25 +02:00
..
animation tst_qanimationgroup: fix memleaks 2022-01-05 08:22:00 +01:00
global Move some purely floating-point testing from tst_QLocale to tst_QNumeric 2022-04-01 23:11:35 +02:00
io Don't declare type 'id' in the global namespace in a public header 2022-04-27 00:16:26 +02:00
itemmodels QAbstractProxyModel: do not access invalid indexes 2022-04-13 18:08:38 +02:00
kernel Generate JNI signature strings at compile time 2022-05-05 07:29:25 +02:00
mimetypes Tests: Do not depend on transitive includes 2022-03-17 17:14:37 +01:00
platform Android: Add runOnMainAndroidThread() under QNativeInterface 2021-05-26 23:24:11 +00:00
plugin Android: activate tst_QPluginLoader 2022-03-30 19:05:59 +02:00
serialization QTextStream: complete char16_t support 2022-05-04 07:09:22 +02:00
text Deprecate _qs and _qba literal operators in favor of _s and _ba 2022-05-02 12:23:56 +02:00
thread Add support for unwrapping QFuture<QFuture<T>> 2022-04-21 20:25:13 +00:00
time Replace remaining uses of deprecated _qs with _s 2022-05-02 12:23:44 +02:00
tools QVarLengthArray: add missing (size, value) ctor 2022-04-13 08:10:47 +02:00
CMakeLists.txt Add tests for QAndroidApplication's sdkVersion and activity 2021-05-13 01:41:36 +03:00