* params.c: Fix formatting.
[official-gcc.git] / libjava / testsuite / libjava.jni / cxxtest.cc
blob577273bb5a2e16a1acbf3dffba66ad20fcaaff8d
1 #include <jni.h>
2 #include <cxxtest.h>
4 jobjectArray
5 Java_cxxtest_fetch (JNIEnv *env, jobject _this)
7 jclass cls;
8 jfieldID fid;
9 jobjectArray obj;
11 cls = env->GetObjectClass (_this);
12 if (! cls)
13 return 0;
15 fid = env->GetFieldID (cls, "F", "[Ljava/lang/Object;");
16 if (! fid)
17 return 0;
19 obj = reinterpret_cast<jobjectArray> (env->GetObjectField (_this, fid));
21 return obj;