jboolean* JPJavaEnv::GetBooleanArrayElements(jbooleanArray array, jboolean* isCopy) { JNIEnv* env = getJNIEnv(); jboolean* res = env->functions->GetBooleanArrayElements(env, array, isCopy); JAVA_CHECK("GetBooleanArrayElements"); return res; }
jbooleanArray JPJavaEnv::NewBooleanArray(jint len) { JNIEnv* env = getJNIEnv(); jbooleanArray res = env->functions->NewBooleanArray(env, len); JAVA_CHECK("NewBooleanArray"); return res; }
jdouble JPJavaEnv::GetStaticDoubleField(jclass clazz, jfieldID fid) { JNIEnv* env = getJNIEnv(); jdouble res = env->functions->GetStaticDoubleField(env, clazz, fid); JAVA_CHECK("GetStaticDoubleField"); return res; }
jboolean JPJavaEnv::GetStaticBooleanField(jclass clazz, jfieldID fid) { JNIEnv* env = getJNIEnv(); jboolean res = env->functions->GetStaticBooleanField(env, clazz, fid); JAVA_CHECK("GetStaticBooleanField"); return res; }
jobject JPJavaEnv::GetObjectField(jobject clazz, jfieldID fid) { JNIEnv* env = getJNIEnv(); jobject res = env->functions->GetObjectField(env, clazz, fid); JAVA_CHECK("GetObjectField"); return res; }
jint JPJavaEnv::AttachCurrentThreadAsDaemon() { // TODO find a way to get A JVM once JPJavaEnv is not a singleton anymore ... JNIEnv* env; jint res = jvm->functions->AttachCurrentThreadAsDaemon(jvm, (void**)&env, NULL); JAVA_CHECK("AttachCurrentThreadAsDaemon"); return res; }
const jchar* JPJavaEnv::GetStringChars(jstring a0, jboolean* a1) { const jchar* res; JNIEnv* env = getJNIEnv(); res = env->functions->GetStringChars(env, a0, a1); JAVA_CHECK("GetStringChars"); return res; }
jsize JPJavaEnv::GetStringLength(jstring a0) { jsize res; JNIEnv* env = getJNIEnv(); res = env->functions->GetStringLength(env, a0); JAVA_CHECK("GetStringLength"); return res; }
jobject JPJavaEnv::NewObject(jclass a0, jmethodID a1) { jobject res; JNIEnv* env = getJNIEnv(); void* _save = JPEnv::getHost()->gotoExternal(); res = env->functions->AllocObject(env, a0); JAVA_CHECK("NewObject"); env->functions->CallVoidMethod(env, res, a1); if (ExceptionCheck()) { DeleteLocalRef(res); } JPEnv::getHost()->returnExternal(_save); JAVA_CHECK("NewObject"); return res; }
jobject JPJavaEnv::NewDirectByteBuffer(void* address, jlong capacity) { TRACE_IN("JPJavaEnv::NewDirectByteBuffer"); JNIEnv* env = getJNIEnv(); jobject res = env->functions->NewDirectByteBuffer(env, address, capacity); JAVA_CHECK("NewDirectByteBuffer"); TRACE1((long)res); return res; TRACE_OUT; }
void JPJavaEnv::CallVoidMethod(jobject a0, jmethodID a1) { JNIEnv* env = getJNIEnv(); void* _save = JPEnv::getHost()->gotoExternal(); env->functions->CallVoidMethod(env, a0, a1); JPEnv::getHost()->returnExternal(_save); JAVA_CHECK("CallVoidMethod"); }
void JPJavaEnv::CallStaticVoidMethodA(jclass a0, jmethodID a1, jvalue* a2) { JNIEnv* env = getJNIEnv(); void* _save = JPEnv::getHost()->gotoExternal(); env->functions->CallStaticVoidMethodA(env, a0, a1, a2); JPEnv::getHost()->returnExternal(_save); JAVA_CHECK("CallStaticVoidMethodA"); }
void JPJavaEnv::SetObjectArrayElement(jobjectArray a0, int a1, jobject a2) { JNIEnv* env = getJNIEnv(); void* _save = JPEnv::getHost()->gotoExternal(); env->functions->SetObjectArrayElement(env, a0, a1, a2); JPEnv::getHost()->returnExternal(_save); JAVA_CHECK("SetObjectArrayElement"); }
void JPJavaEnv::ReleaseStringUTFChars(jstring a0, const char* a1) { JNIEnv* env = getJNIEnv(); void* _save = JPEnv::getHost()->gotoExternal(); env->functions->ReleaseStringUTFChars(env, a0, a1); JPEnv::getHost()->returnExternal(_save); JAVA_CHECK("ReleaseStringUTFChars"); }
jclass JPJavaEnv::DefineClass(const char* a0, jobject a1, const jbyte* a2, jsize a3) { jclass res; JNIEnv* env = getJNIEnv(); void* _save = JPEnv::getHost()->gotoExternal(); res = env->functions->DefineClass(env, a0, a1, a2, a3); JPEnv::getHost()->returnExternal(_save); JAVA_CHECK("DefineClass"); return res; }
jobjectArray JPJavaEnv::NewObjectArray(int a0, jclass a1, jobject a2) { jobjectArray res; JNIEnv* env = getJNIEnv(); void* _save = JPEnv::getHost()->gotoExternal(); res = env->functions->NewObjectArray(env, a0, a1, a2); JPEnv::getHost()->returnExternal(_save); JAVA_CHECK("NewObjectArray"); return res; }
jboolean JPJavaEnv::IsInstanceOf(jobject a0, jclass a1) { jboolean res; JNIEnv* env = getJNIEnv(); void* _save = JPEnv::getHost()->gotoExternal(); res = env->functions->IsInstanceOf(env, a0, a1); JPEnv::getHost()->returnExternal(_save); JAVA_CHECK("IsInstanceOf"); return res; }
jclass JPJavaEnv::GetObjectClass(jobject a0) { jclass res; JNIEnv* env = getJNIEnv(); void* _save = JPEnv::getHost()->gotoExternal(); res = env->functions->GetObjectClass(env, a0); JPEnv::getHost()->returnExternal(_save); JAVA_CHECK("GetObjectClass"); return res; }
jfieldID JPJavaEnv::GetStaticFieldID(jclass a0, const char* a1, const char* a2) { jfieldID res; JNIEnv* env = getJNIEnv(); void* _save = JPEnv::getHost()->gotoExternal(); res = env->functions->GetStaticFieldID(env, a0, a1, a2); JPEnv::getHost()->returnExternal(_save); JAVA_CHECK("GetStaticFieldID"); return res; }
jclass JPJavaEnv::FindClass(const char* a0) { jclass res; JNIEnv* env = getJNIEnv(); void* _save = JPEnv::getHost()->gotoExternal(); res = env->functions->FindClass(env, a0); JPEnv::getHost()->returnExternal(_save); JAVA_CHECK("FindClass"); return res; }
jsize JPJavaEnv::GetArrayLength(jarray a0) { jsize res; JNIEnv* env = getJNIEnv(); void* _save = JPEnv::getHost()->gotoExternal(); res = env->functions->GetArrayLength(env, a0); JPEnv::getHost()->returnExternal(_save); JAVA_CHECK("GetArrayLength"); return res; }
jboolean JPJavaEnv::IsAssignableFrom(jclass a0, jclass a1) { jboolean res; JNIEnv* env = getJNIEnv(); void* _save = JPEnv::getHost()->gotoExternal(); res = env->functions->IsAssignableFrom(env, a0, a1); JPEnv::getHost()->returnExternal(_save); JAVA_CHECK("IsAssignableFrom"); return res; }
jint JPJavaEnv::RegisterNatives(jclass a0, const JNINativeMethod* a1, jint a2) { jint res; JNIEnv* env = getJNIEnv(); void* _save = JPEnv::getHost()->gotoExternal(); res = env->functions->RegisterNatives(env, a0, a1, a2); JPEnv::getHost()->returnExternal(_save); JAVA_CHECK("RegisterNatives"); return res; }
jstring JPJavaEnv::NewString(const jchar* a0, int a1) { jstring res; JNIEnv* env = getJNIEnv(); void* _save = JPEnv::getHost()->gotoExternal(); res = env->functions->NewString(env, a0, a1); JPEnv::getHost()->returnExternal(_save); JAVA_CHECK("NewString"); return res; }
int JPJavaEnv::MonitorExit(jobject a0) { int res; JNIEnv* env = getJNIEnv(); void* _save = JPEnv::getHost()->gotoExternal(); res = env->functions->MonitorExit(env, a0); JPEnv::getHost()->returnExternal(_save); JAVA_CHECK("MonitorExit"); return res; }
jobject JPJavaEnv::GetObjectArrayElement(jobjectArray a0, int a1) { jobject res; JNIEnv* env = getJNIEnv(); void* _save = JPEnv::getHost()->gotoExternal(); res = env->functions->GetObjectArrayElement(env, a0, a1); JPEnv::getHost()->returnExternal(_save); JAVA_CHECK("GetObjectArrayElement"); return res; }
const char* JPJavaEnv::GetStringUTFChars(jstring a0, jboolean* a1) { const char* res; JNIEnv* env = getJNIEnv(); void* _save = JPEnv::getHost()->gotoExternal(); res = env->functions->GetStringUTFChars(env, a0, a1); JPEnv::getHost()->returnExternal(_save); JAVA_CHECK("GetStringUTFChars"); return res; }
jfieldID JPJavaEnv::FromReflectedField(jobject a0) { jfieldID res; JNIEnv* env = getJNIEnv(); void* _save = JPEnv::getHost()->gotoExternal(); res = env->functions->FromReflectedField(env, a0); JPEnv::getHost()->returnExternal(_save); JAVA_CHECK("FromReflectedField"); return res; }
jboolean JPJavaEnv::CallNonvirtualBooleanMethod(jobject obj, jclass claz, jmethodID mid) { jboolean res; JNIEnv* env = getJNIEnv(); void* _save = JPEnv::getHost()->gotoExternal(); res = env->functions->CallNonvirtualBooleanMethod(env, obj, claz, mid); JPEnv::getHost()->returnExternal(_save); JAVA_CHECK("Boolean"); return res; }
jboolean JPJavaEnv::CallBooleanMethodA(jobject obj, jmethodID mid, jvalue* val) { jboolean res; JNIEnv* env = getJNIEnv(); void* _save = JPEnv::getHost()->gotoExternal(); res = env->functions->CallBooleanMethodA(env, obj, mid, val); JPEnv::getHost()->returnExternal(_save); JAVA_CHECK("Boolean"); return res; }