diff options
author | Tor Andersson <tor.andersson@artifex.com> | 2016-02-22 14:58:33 +0100 |
---|---|---|
committer | Tor Andersson <tor.andersson@artifex.com> | 2016-02-29 16:03:34 +0100 |
commit | e45a2f494d0a4f7e11c544d2098b0f5d1d199e58 (patch) | |
tree | f8516071dafdf758ff00237b9af7375d3c3f6d76 /platform/java/com/artifex/mupdf/fitz/Context.java | |
parent | a6e15a6c904f700543429d94c703a4d1911e1ac2 (diff) | |
download | mupdf-e45a2f494d0a4f7e11c544d2098b0f5d1d199e58.tar.xz |
jni: Move java bindings to platform/java.
Move the platform independent java code from platform/android to
platform/java.
The plan is that we can call 'make mupdf.jar' (or 'nmake mupdf.jar')
there, and then use the resultant mupdf.jar/mupdf_native.h files in
whatever platform specific project (such as the android bindings) we
like.
Keep the android specific class (AndroidDrawDevice) in the
usual place in platform/android.
Update the android ant script to include mupdf.jar.
Diffstat (limited to 'platform/java/com/artifex/mupdf/fitz/Context.java')
-rw-r--r-- | platform/java/com/artifex/mupdf/fitz/Context.java | 20 |
1 files changed, 20 insertions, 0 deletions
diff --git a/platform/java/com/artifex/mupdf/fitz/Context.java b/platform/java/com/artifex/mupdf/fitz/Context.java new file mode 100644 index 00000000..1baafb01 --- /dev/null +++ b/platform/java/com/artifex/mupdf/fitz/Context.java @@ -0,0 +1,20 @@ +package com.artifex.mupdf.fitz; + +// This class handles the loading of the MuPDF shared library, together +// with the ThreadLocal magic to get the required context. +// +// The only publicly accessible method here is Context.setStoreSize, which +// sets the store size to use. This must be called before any other MuPDF +// function. +public class Context +{ + // Load our native library + static + { + System.loadLibrary("mupdf"); + } + + // FIXME: We should support the store size being changed dynamically. + // This requires changes within the MuPDF core. + //public native static void setStoreSize(long newSize); +} |