Click to See Complete Forum and Search --> : Using a DLL


gal12
January 1st, 2010, 05:32 AM
Hello,

I am currently trying to create a server application, for a client that is already built. The client uses an external dll written in C++ for network communication. Apperantly, that networking protocoal is different than Java's API Socket package, therefore I have to use that dll (which i've got) for networking.

"Googling" it, i've found out that i have to use JNI or JNA to implement that dll in my project. I am not quite sure how to do that. Can anyone help?

Happy new year

dlorde
January 1st, 2010, 08:21 AM
You need to create an JNI native header and implmentation to map the C++ DLL methods to Java methods. Check out the JNI Tutorial (http://java.sun.com/developer/onlineTraining/Programming/JDCBook/jni.html).

If I had eight hours to chop down a tree, I would spend 6 hours sharpening an axe...
Anon.

ProgramThis
January 6th, 2010, 08:19 AM
Thanks for the information.
<censored links>
This isn't the place to advertise your web sites and try to get some link backs.