# Class JConsole.BlockingPipedInputStream

java.lang.Object
java.io.InputStream
java.io.PipedInputStream
bsh.util.JConsole.BlockingPipedInputStream

All Implemented Interfaces:
  `Closeable, AutoCloseable`

Enclosing class:
  `JConsole`

public static class JConsole.BlockingPipedInputStream extends PipedInputStream
The overridden read method in this class will not throw "Broken pipe" IOExceptions; It will simply wait for new writers and data. This is used by the JConsole internal read thread to allow writers in different (and in particular ephemeral) threads to write to the pipe. It also checks a little more frequently than the original read(). Warning: read() will not even error on a read to an explicitly closed pipe (override closed to for that).

## Field Summary

### Fields inherited from class PipedInputStream

`buffer, in, out, PIPE_SIZE`

## Constructor Summary

Constructors
Constructor
Description
`BlockingPipedInputStream(PipedOutputStream pout)`

## Method Summary

Modifier and Type
Method
Description
`void`
`close()`
`int`
`read()`

### Methods inherited from class PipedInputStream

`available, connect, read, receive`

### Methods inherited from class InputStream

`mark, markSupported, nullInputStream, read, readAllBytes, readNBytes, readNBytes, reset, skip, skipNBytes, transferTo`

### Methods inherited from class Object

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

## Constructor Details

### BlockingPipedInputStream

public BlockingPipedInputStream(PipedOutputStream pout) throws IOException

Throws:
  `IOException`

## Method Details

### read

public int read() throws IOException

Overrides:
  `read` in class `PipedInputStream`
Throws:
  `IOException`

### close

public void close() throws IOException

Specified by:
  `close` in interface `AutoCloseable`
Specified by:
  `close` in interface `Closeable`
Overrides:
  `close` in class `PipedInputStream`
Throws:
  `IOException`