Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #if __ANDROID__
- #include <jni.h>
- JNIEXPORT jbyteArray JNICALL
- Java_com_my_company_TestClass_process(JNIEnv *env, jobject thiz, jbyteArray command);
- #endif
- #endif
- apply plugin: 'com.android.library'
- android {
- ...
- sourceSets.main {
- jniLibs.srcDir 'src/main/jniLibs'
- }
- }
- public class TestClass
- {
- public native byte[] process(byte[] command);
- static
- {
- System.loadLibrary("nativelib");
- }
- ...
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement