Qt
Internal/Contributor docs for the Qt SDK. Note: These are NOT official API docs; those are found at https://doc.qt.io/
Loading...
Searching...
No Matches
qjniobject.cpp File Reference

(5f7aad7de4dbbf32788cfc228066c4bfee8043fb)

#include "qjniobject.h"
#include "qjnihelpers_p.h"
#include <QtCore/qbytearray.h>
#include <QtCore/qhash.h>
#include <QtCore/qreadwritelock.h>
#include <QtCore/qloggingcategory.h>
Include dependency graph for qjniobject.cpp:

Go to the source code of this file.

Classes

class  QJniObjectPrivate
struct  JClassHash

Typedefs

typedef QHash< QByteArray, jmethodID > JMethodIDHash
typedef QHash< QByteArray, jfieldID > JFieldIDHash

Functions

template<typename ... Args>
static QByteArray cacheKey (Args &&...args)
static jclass getCachedClass (const QByteArray &className)
static QJniObject getCleanJniObject (jobject object, JNIEnv *env)

Typedef Documentation

◆ JFieldIDHash

typedef QHash< QByteArray, jfieldID > JFieldIDHash

Definition at line 608 of file qjniobject.cpp.

◆ JMethodIDHash

typedef QHash< QByteArray, jmethodID > JMethodIDHash

Definition at line 544 of file qjniobject.cpp.

Function Documentation

◆ cacheKey()

template<typename ... Args>
QByteArray cacheKey ( Args &&... args)
inlinestatic

Definition at line 381 of file qjniobject.cpp.

◆ getCachedClass()

jclass getCachedClass ( const QByteArray & className)
static

Definition at line 393 of file qjniobject.cpp.

◆ getCleanJniObject()

QJniObject getCleanJniObject ( jobject object,
JNIEnv * env )
static

Get a JNI object from a jobject variant and do the necessary exception clearing and delete the local reference before returning. The JNI object can be null if there was an exception.

Definition at line 430 of file qjniobject.cpp.