JNI example in C and C++