Print Page | Close Window

Problem with debenu_quick_pdf_library_android

Printed From: Debenu Quick PDF Library - PDF SDK Community Forum
Category: For Users of the Library
Forum Name: I need help - I can help
Forum Description: Problems and solutions while programming with the Debenu Quick PDF Library and Debenu PDF Viewer SDK
URL: http://www.quickpdf.org/forum/forum_posts.asp?TID=3118
Printed Date: 29 Apr 24 at 1:05PM
Software Version: Web Wiz Forums 11.01 - http://www.webwizforums.com


Topic: Problem with debenu_quick_pdf_library_android
Posted By: Ludwig
Subject: Problem with debenu_quick_pdf_library_android
Date Posted: 18 May 15 at 3:01PM
The AndroidStudio_sample does not have an interface (.i) file. How can I get it. The sample appears to be using SWIG for generating the JNI code. Do we need to write the interface files ourselves



Replies:
Posted By: Marek
Date Posted: 22 May 15 at 8:38AM
Hello Ludwig,
 
The interface file is not needed, and you don't need to create your own interface files.
The swig was used to create the java wrapper that was then included and compiled into the .so file. So look at the sample project to see how to use it.
 
Go to the app/src/main/java directory in the sample project.
There you will find 2 packages.
com.debenu.pdflibrary.* and com.debenu.dqplandroidexample
 
pdflibrary package has 2 files FlatAPIJNI.java which is a jni interface that can call the functions in .so file
the second file is dpl.java which uses the FlatAPIJNI.
 
In your application you have to just import the library package like this:
 
import com.debenu.pdflibrary.DPL;
 
and then you can use the library functions.
Check the dqplandroidexample package, inside it is MainActivity.java file that imports the library package and then uses it.
 
First thing you must do before compilation of the sample project is to search in the MainActivity.java code for this string "...TYPE_YOUR_KEY_HERE..."
You need to replace this string with your library key to unlock it. After that you can use all the functions.
Review the MainActivity.java code for yourself to see how to use the library.



Print Page | Close Window

Forum Software by Web Wiz Forums® version 11.01 - http://www.webwizforums.com
Copyright ©2001-2014 Web Wiz Ltd. - http://www.webwiz.co.uk