This week's book giveaway is in the Servlets forum.
We're giving away four copies of Murach's Java Servlets and JSP and have Joel Murach on-line!
See this thread for details.
The moose likes Other JSE/JEE APIs and the fly likes Using native code Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Murach's Java Servlets and JSP this week in the Servlets forum!
JavaRanch » Java Forums » Java » Other JSE/JEE APIs
Bookmark "Using native code" Watch "Using native code" New topic
Author

Using native code

Ransika deSilva
Ranch Hand

Joined: Feb 18, 2003
Posts: 524
Hello world,
I have this assignment to do. It is that, the user is allowed to enter a process name and when entered, if that perticular process is running, the program should give the attributes of the process. From the information I gathered so far, I understood that, it is not possible to do it with Java. I have to use some other languge such as C++. Could you please tell me how to combine these to languages, and say if the C++ codes results in an array of data, how to get them directly to an array in Java in the program.
Thank you in advance....................


SCJP 1.4, SCMAD 1.0<br />SCWCD, SCBCD (in progress)
Dmitry Melnik
Ranch Hand

Joined: Dec 18, 2003
Posts: 328
Try reading this first http://java.sun.com/docs/books/tutorial/native1.1/TOC.html
I assume you know how to program in C++
Dirk Schreckmann
Sheriff

Joined: Dec 10, 2001
Posts: 7023
You're perhaps going to want to get into JNI. So, I'm moving this to the Other Java APIs forum, where folks just love to talk about JNI.


[How To Ask Good Questions] [JavaRanch FAQ Wiki] [JavaRanch Radio]
 
It is sorta covered in the JavaRanch Style Guide.
 
subject: Using native code
 
Similar Threads
how to convert jchararray to char array.
How to start self learning Java
JNI problem, pasing String to native (C function) by reference
adding Process into an Array
Calling a Java program in a C program