Back to index

lightning-sunbird  0.9+nobinonly
Defines | Typedefs | Functions
JNIEnvTests.h File Reference
#include "nsIServiceManager.h"
#include "nsIJVMManager.h"
#include "nsJVMManager.h"
#include "ojiapitests.h"

Go to the source code of this file.


#define SecENV   TRUE
#define MAX_JLONG   9223372036854775807
#define MIN_JLONG   -9223372036854775808
#define MAX_JINT   2147483647
#define MIN_JINT   -2147483648
#define MAX_JDOUBLE   1.7976931348623157E308
#define MIN_JDOUBLE   4.9E-324
#define MAX_JBYTE   127
#define MIN_JBYTE   -128
#define MAX_JFLOAT   3.4028235E38F
#define MIN_JFLOAT   1.4E-45F
#define MAX_JSHORT   32767
#define MIN_JSHORT   -32768


typedef unsigned char byte


nsresult GetJNI (JNIEnv **env)

Define Documentation

#define MAX_JBYTE   127

Definition at line 72 of file JNIEnvTests.h.

#define MAX_JDOUBLE   1.7976931348623157E308

Definition at line 70 of file JNIEnvTests.h.

#define MAX_JFLOAT   3.4028235E38F

Definition at line 74 of file JNIEnvTests.h.

#define MAX_JINT   2147483647

Definition at line 68 of file JNIEnvTests.h.

#define MAX_JLONG   9223372036854775807

Definition at line 64 of file JNIEnvTests.h.

#define MAX_JSHORT   32767

Definition at line 76 of file JNIEnvTests.h.

#define MIN_JBYTE   -128

Definition at line 73 of file JNIEnvTests.h.

#define MIN_JDOUBLE   4.9E-324

Definition at line 71 of file JNIEnvTests.h.

#define MIN_JFLOAT   1.4E-45F

Definition at line 75 of file JNIEnvTests.h.

#define MIN_JINT   -2147483648

Definition at line 69 of file JNIEnvTests.h.

#define MIN_JLONG   -9223372036854775808

Definition at line 65 of file JNIEnvTests.h.

#define MIN_JSHORT   -32768

Definition at line 77 of file JNIEnvTests.h.

Definition at line 51 of file JNIEnvTests.h.

Typedef Documentation

typedef unsigned char byte

Definition at line 58 of file JNIEnvTests.h.

Function Documentation

nsresult GetJNI ( JNIEnv **  env)

Definition at line 40 of file get_jni.cpp.

       nsIJVMManager *jvmMngr = nsnull;
       nsresult rv = NS_OK;
       *env = nsnull;
       rv = CallGetService(kJVMManagerCID, &jvmMngr);
       if (rv != NS_OK || !jvmMngr) {
              fprintf(stderr, "ERROR: Can't get JVM manager !\n");
              return NS_ERROR_FAILURE;
       if (NS_SUCCEEDED(jvmMngr->GetProxyJNI(env)) && *env)
              return NS_OK;
       fprintf(stderr, "ERROR: Can't get JNI env !\n");
       return NS_ERROR_FAILURE;

Here is the call graph for this function:

static NS_DEFINE_CID ( kJVMManagerCID  ,
) [static]
static NS_DEFINE_IID ( kIJVMManagerIID  ,
) [static]