Back to index

lightning-sunbird  0.9+nobinonly
IsSameObject_2.cpp File Reference
#include "JNIEnvTests.h"
#include "ObjectOperations.h"

Go to the source code of this file.


 JNI_OJIAPITest (JNIEnv_IsSameObject_2)

Function Documentation

JNI_OJIAPITest ( JNIEnv_IsSameObject_2  )

Definition at line 40 of file IsSameObject_2.cpp.


  jclass clazz  = env->FindClass("Test1");
  jclass clazz1 = env->FindClass("Test1");
  jobject obj1 = env->AllocObject(clazz1);
  jobject obj2 = env->AllocObject(clazz1);
  jobject obj = env->AllocObject(clazz);

  if(env->IsSameObject(obj1, obj2) == JNI_TRUE){
      return TestResult::FAIL("IsSameObject(obj, another obj) return incorrect value");
      return TestResult::PASS("IsSameObject(obj, another obj) return correct value");


Here is the call graph for this function: