Monday, July 16, 2001 06:25 PM
Java doesn't give you direct access to non-portable capabilities like Unix/Linux pipes. You can still do quite a few things with pipes, for example:
Create a named pipe by invoking the mkfifo utility in a Runtime.exec() method.
Open a named pipe by name - which is just like opening a file.
Run an external process with Runtime.exec() and access its input and output streams via the Process.getInputStream() and Process.getOutputStream() methods.
Maybe these are enough to solve your problem? If not - that is, if you need to get to the pipe() system call - you'll need to write your own JNI code to do it.