I have a structure defined in my native c library and i want to pass it to the java. In java then i want to access this structure elements. How to do this. Can anybody explain me with one example showing both c and java code. I will definitely appreciate for the help. Please help me as soon as possible.
Asked
Active
Viewed 534 times
1 Answers
1
Create a Java object in your C code and populate it with the data from the C struct. See the accepted answer for How to pass C structs back and forth to Java code in JNI? for more details.