Package com.pixelmed.transfermonitor

# Class MonitoredInputStream

java.lang.Object
java.io.InputStream
com.pixelmed.transfermonitor.MonitoredInputStream

All Implemented Interfaces:
  `Closeable`, `AutoCloseable`

public class MonitoredInputStream extends InputStream

A class that extends `InputStream` to track statistics on the transfers.

## Constructor Summary

Constructors
Constructor
Description
`MonitoredInputStream(InputStream in, TransferMonitoringContext transferMonitoringContext)`

## Method Summary

Modifier and Type
Method
Description
`final int`
`available()`
`final void`
`close()`
`final void`
`mark(int readlimit)`
`final boolean`
`markSupported()`
`final int`
`read()`
`final int`
`read(byte[] b)`
`final int`
`read(byte[] b, int off, int len)`
`final void`
`reset()`
`final long`
`skip(long n)`

### Methods inherited from class java.io.InputStream

`nullInputStream, readAllBytes, readNBytes, readNBytes, skipNBytes, transferTo`

### Methods inherited from class java.lang.Object

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

## Constructor Details

### MonitoredInputStream

public MonitoredInputStream(InputStream in, TransferMonitoringContext transferMonitoringContext)

## Method Details

### read

public final int read() throws IOException

Specified by:
  `read` in class `InputStream`
Throws:
  `IOException`

### read

public final int read(byte[] b) throws IOException

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

### read

public final int read(byte[] b, int off, int len) throws IOException

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

### skip

public final long skip(long n) throws IOException

Overrides:
  `skip` in class `InputStream`
Throws:
  `IOException`

### available

public final int available() throws IOException

Overrides:
  `available` in class `InputStream`
Throws:
  `IOException`

### close

public final void close() throws IOException

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

### mark

public final void mark(int readlimit)

Overrides:
  `mark` in class `InputStream`

### markSupported

public final boolean markSupported()

Overrides:
  `markSupported` in class `InputStream`

### reset

public final void reset() throws IOException

Overrides:
  `reset` in class `InputStream`
Throws:
  `IOException`