+ stub of Kiwix JNI

This commit is contained in:
kelson42 2013-04-01 19:15:54 +02:00
parent f2f9f19e35
commit 239daec094
3 changed files with 52 additions and 0 deletions

29
JNIKiwix.h Normal file
View File

@ -0,0 +1,29 @@
/* DO NOT EDIT THIS FILE - it is machine generated */
#include <jni.h>
/* Header for class JNIKiwix */
#ifndef _Included_JNIKiwix
#define _Included_JNIKiwix
#ifdef __cplusplus
extern "C" {
#endif
/*
* Class: JNIKiwix
* Method: nativeLoadZIM
* Signature: ()Ljava/lang/Boolean;
*/
JNIEXPORT jobject JNICALL Java_JNIKiwix_nativeLoadZIM
(JNIEnv *, jobject);
/*
* Class: JNIKiwix
* Method: nativeGetContent
* Signature: (Ljava/lang/String;)Ljava/lang/String;
*/
JNIEXPORT jstring JNICALL Java_JNIKiwix_nativeGetContent
(JNIEnv *, jobject, jstring);
#ifdef __cplusplus
}
#endif
#endif

12
JNIKiwix.java Normal file
View File

@ -0,0 +1,12 @@
public class JNIKiwix {
public native Boolean nativeLoadZIM();
public native String nativeGetContent(String url);
static {
System.loadLibrary("kiwix");
}
public static void main(String[] args) {
return;
}
}

11
kiwix.c Normal file
View File

@ -0,0 +1,11 @@
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <jni.h>
#include "JNIKiwix.h"
JNIEXPORT jobject JNICALL Java_JNIKiwix_nativeLoadZIM(JNIEnv *env, jobject obj) {
}
JNIEXPORT jstring JNICALL Java_JNIKiwix_nativeGetContent(JNIEnv *env, jobject obj, jstring url) {
}