PB4Java

Developed or developing a new product in PureBasic? Tell the world about it.
Bonne_den_kule
Addict
Addict
Posts: 841
Joined: Mon Jun 07, 2004 7:10 pm

PB4Java

Post by Bonne_den_kule »

Hello!
It's along time since I was active on this forum and was coding PB. I have somehow return :P by experimenting with accessing PB procedures in Java (using JNI).
I was fascinated by the JNI example by Froggerprogger (http://www.purebasic.fr/english/viewtopic.php?t=23702).
So I made this tool to make the process of creating JNI compatible libraries easier. The PB4Java tool can parse both PB source code files and pure library files (even open multiple files at same the time).
Procedures in source files that are going to be exported must have a name starting with "Java_" (does not apply for pure library files).
All necessary boilerplate code and includes are created without much hassle by clicking on the "Save" button. More information in the readme.
If you have any question, bugs to report or any ideas, please post here :)

Image

Download here.

The tool is created in Java, so you need the Java SE 6 JRE (a whopping 16 MB ;) ).
Last edited by Bonne_den_kule on Sat Oct 31, 2009 8:30 pm, edited 1 time in total.
Fred
Administrator
Administrator
Posts: 18153
Joined: Fri May 17, 2002 4:39 pm
Location: France
Contact:

Re: PB4Java

Post by Fred »

Very interesting, look like dead easy to map PB dll with JNI now.
User avatar
GeoTrail
Addict
Addict
Posts: 2794
Joined: Fri Feb 13, 2004 12:45 am
Location: Bergen, Norway
Contact:

Re: PB4Java

Post by GeoTrail »

Very cool. Works great on Mac OS X Snow Leopard :)
I Stepped On A Cornflake!!! Now I'm A Cereal Killer!
Bonne_den_kule
Addict
Addict
Posts: 841
Joined: Mon Jun 07, 2004 7:10 pm

Re: PB4Java

Post by Bonne_den_kule »

I have now updated the tool. Many new features are added, with the greatest one being is the possibility to parse pure library files.
Rows can be removed from table with the new remove button. A sort function to the table has also been added.
User avatar
Rook Zimbabwe
Addict
Addict
Posts: 4322
Joined: Tue Jan 02, 2007 8:16 pm
Location: Cypress TX
Contact:

Re: PB4Java

Post by Rook Zimbabwe »

This does look incredibly ineresting... do you have any small examples you have created to show it off? 8)
Binarily speaking... it takes 10 to Tango!!!

Image
http://www.bluemesapc.com/
Bonne_den_kule
Addict
Addict
Posts: 841
Joined: Mon Jun 07, 2004 7:10 pm

Re: PB4Java

Post by Bonne_den_kule »

Rook Zimbabwe wrote:This does look incredibly ineresting... do you have any small examples you have created to show it off? 8)
Thanks :) There is an example file in the zip file. But I can make some more examples with usage of pure libraries functions, and then make a new release or post the examples here.
Bonne_den_kule
Addict
Addict
Posts: 841
Joined: Mon Jun 07, 2004 7:10 pm

Re: PB4Java

Post by Bonne_den_kule »

Bonne_den_kule wrote:
Rook Zimbabwe wrote:This does look incredibly ineresting... do you have any small examples you have created to show it off? 8)
Thanks :) There is an example file in the zip file. But I can make some more examples with usage of pure libraries functions, and then make a new release or post the examples here.
I have added a quick guide and one more example to the zip file. You'll find the stash in the example directory :)
Post Reply