processing.app.exec

## Class StreamPump

- Object
- - StreamPump

- All Implemented Interfaces:
    Runnable

      public class StreamPump
      extends Object
      implements Runnable

  A StreamPump reads lines of text from its given InputStream and informs its LineProcessors until the InputStream is exhausted. It is useful only for pumping lines of text, and not for arbitrary binary cruft. It's handy for reading the output of processes that emit textual data, for example.

- - ### Constructor Summary

    Constructors
    Constructor and Description
    `StreamPump(InputStream in, String name)`

  - ### Method Summary

    All Methods Instance Methods Concrete Methods
    Modifier and Type | Method and Description
    --- | ---
    `StreamPump` | `addTarget(LineProcessor out)`
    `StreamPump` | `addTarget(OutputStream out)`
    `StreamPump` | `addTarget(Writer out)`
    `void` | `run()`
    `void` | `start()`

    - ### Methods inherited from class Object

      `equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

- - ### Constructor Detail

    - #### StreamPump

          public StreamPump(InputStream in,
                            String name)

  - ### Method Detail

    - #### addTarget

          public StreamPump addTarget(OutputStream out)

    - #### addTarget

          public StreamPump addTarget(Writer out)

    - #### addTarget

          public StreamPump addTarget(LineProcessor out)

    - #### start

          public void start()

    - #### run

          public void run()

      Specified by:
        `run` in interface `Runnable`