On 17 Jun 2015, at 16:56, obsidian <
stephe...@gmail.com> wrote:
> I have a C++ library I am accessing using JNA. During operation it prints various pieces of information to the stdout, which I would like to be able to capture within Java. The prints appear on the output, so I assume that it should be possible to do this.
This is not really a Java nor JNA question.
You need to figure out how to do that on the C/C++ side and you can then bring the data over to Java and this is where JNA can help.
How ever, if you are on Unix/Linux/Mac OS you could possibly just pipe the output to a socked and read that directly in Java…come to think of it, you can execute any program from Java directly and capture the output, this would be the easiest if can compile your C++ lib to an application that can be executed.
br Kusti
This e-mail may contain confidential or privileged information. If you are not the intended recipient (or have received this e-mail in error) please notify the sender immediately and destroy this e-mail. Any unauthorized copying, disclosure or distribution of the material in this e-mail is strictly forbidden. We will not be liable for direct, indirect, special or consequential damages arising from alteration of the contents of this message by a third party or as a result of any virus being passed on or as of transmission of this e-mail in general.