Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Reading shared memory data using Java that is written by C++

I have an application in C/C++ that writes data in shared memory in Unix. Now I want to read that shared memory data through a program using Java.

The program should read the shared memory data. Can it be possible?

Need a small implementation if possible.

like image 297
Nikhil Avatar asked Jan 08 '13 08:01

Nikhil


1 Answers

Take a look at this codeproject project (For Windows):

Using Memory Mapped Files and JNI to communicate between Java and C++ programs

Or, this library:

CLIPC is an open-source Java library that gives developers interprocess communications (IPC) capabilities that may be absent or difficult to use in the Java distribution.

like image 93
masoud Avatar answered Sep 18 '22 23:09

masoud