org.ops4j.io
Class Pipe

java.lang.Object
  extended by org.ops4j.io.Pipe

public class Pipe
extends Object

Pipes asynchronously transfer data between process and system streams.


Constructor Summary
Pipe(InputStream processStream, OutputStream systemStream)
          Create an incoming pipe, from the external process to us.
Pipe(OutputStream processStream, InputStream systemStream)
          Create an outgoing pipe, from us to the external process.
 
Method Summary
 Pipe start(String name)
          Start piping data from input to output.
 void stop()
          Stop piping data from input to output.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

Pipe

public Pipe(InputStream processStream,
            OutputStream systemStream)
Create an incoming pipe, from the external process to us.

Parameters:
processStream - process source
systemStream - system sink

Pipe

public Pipe(OutputStream processStream,
            InputStream systemStream)
Create an outgoing pipe, from us to the external process.

Parameters:
processStream - process sink
systemStream - system source
Method Detail

start

public Pipe start(String name)
Start piping data from input to output.

Parameters:
name - pipe name
Returns:
pipe instance

stop

public void stop()
Stop piping data from input to output.



Copyright © 2006-2013 OPS4J - Open Participation Software for Java. All Rights Reserved.