I have an object that is calling a JNI function which written in C.

Philip Yu

Your Name class can provide a set of setter/getter functions for the two member variables, like the following:

     public void setFirstName(String first){};
     public String getFirstName() {};
In your native code, use GetMethodID() to reference your functions and set the member variables accordingly.

The Get(type)Field() does not support the jstring type.