Back to index

lightning-sunbird  0.9+nobinonly
Classes | Functions
lcglue.h File Reference
#include "prtypes.h"
#include "jni.h"
#include "jsdbgapi.h"
#include "nsError.h"
#include "nsIThreadManager.h"
#include "nsISecurityContext.h"
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Classes

struct  JVMContext
 JVMContext is maintained as thread local storage. More...

Functions

JVMContextGetJVMContext ()
void JVM_InitLCGlue (void)

Class Documentation

struct JVMContext

JVMContext is maintained as thread local storage.

The current thread's context is accessed by calling GetJVMContext().

Definition at line 53 of file lcglue.h.

Collaboration diagram for JVMContext:
Class Members
JSJavaThreadState * jsj_env
JNIEnv * proxyEnv

Function Documentation

Definition at line 104 of file lcglue.cpp.

{
       /* Use NSPR thread private data to manage the per-thread JNIEnv* association. */
       static ThreadLocalStorage<JVMContext*> localContext((PRThreadPrivateDTOR)&detach_JVMContext);
       JVMContext* context = localContext.get();
       if (context == NULL) {
              context = new JVMContext;
              context->proxyEnv = NULL;
              context->jsj_env = NULL;
              localContext.set(context);
       }
       return context;
}

Here is the call graph for this function:

Here is the caller graph for this function:

Definition at line 404 of file lcglue.cpp.

Here is the call graph for this function:

Here is the caller graph for this function: