?
Solved

How do I pack java code inside a DLL to use with C++

Posted on 2009-03-31
1
Medium Priority
?
297 Views
Last Modified: 2013-12-14
Does anybody know how I can put java code inside a dll file and after that call that code inside a C++ program?

Do I put the java code inside a COM object that I put inside C++?

And if that is true can I call that object from inside a C++ program to use the java code in the dll?

Or do I use another approach?

Is it even possible?
0
Comment
Question by:Choklander
1 Comment
 
LVL 19

Accepted Solution

by:
alb66 earned 2000 total points
ID: 24026967
In order to call Java code from C++ you can use the Invocation Interface (a part of the Java Native Interface [JNI] ).
For greater details look at http://java.sun.com/docs/books/jni/html/invoke.html#11202
0

Featured Post

Vote for the Most Valuable Expert

It’s time to recognize experts that go above and beyond with helpful solutions and engagement on site. Choose from the top experts in the Hall of Fame or on the right rail of your favorite topic page. Look for the blue “Nominate” button on their profile to vote.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Introduction Java can be integrated with native programs using an interface called JNI(Java Native Interface). Native programs are programs which can directly run on the processor. JNI is simply a naming and calling convention so that the JVM (Java…
Introduction This article is the last of three articles that explain why and how the Experts Exchange QA Team does test automation for our web site. This article covers our test design approach and then goes through a simple test case example, how …
This tutorial covers a practical example of lazy loading technique and early loading technique in a Singleton Design Pattern.
This tutorial will introduce the viewer to VisualVM for the Java platform application. This video explains an example program and covers the Overview, Monitor, and Heap Dump tabs.
Suggested Courses
Course of the Month16 days, 17 hours left to enroll

862 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question