JavaVM *javaVM = NULL; JNIEnv *jniEnv = NULL;
( createJavaVM )( &javaVM, ( void * )&jniEnv, &javaVMInitArgs )
where javaVM * and jniEnv * are global variables
JavaVM *javaVM = NULL; JNIEnv *jniEnv = NULL;
( createJavaVM )( &javaVM, ( void * )&jniEnv, &javaVMInitArgs )
where javaVM * and jniEnv * are global variables
Yes.
No. That represents a context for a specific JNI method invocation. It is dependent on the current thread, the arguments to the current method, the local references that have been created by the current method, all sorts of things, and it becomes invalid once that JNI method returns.