Package fr.gouv.vitam.common.stream

# Class SizedInputStream

java.lang.Object
java.io.InputStream
fr.gouv.vitam.common.stream.SizedInputStream

All Implemented Interfaces:
  `Closeable`, `AutoCloseable`

public class SizedInputStream extends InputStream
Input stream with read size

- ## Constructor Summary

  Constructors
  Constructor
  Description
  `SizedInputStream(InputStream is)`
  Default constructor

- ## Method Summary

  Modifier and Type
  Method
  Description
  `long`
  `getSize()`
  Get read size
  `int`
  `read()`
  `int`
  `read(byte[] b)`
  `int`
  `read(byte[] b, int off, int len)`

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

  `available, close, mark, markSupported, nullInputStream, readAllBytes, readNBytes, readNBytes, reset, skip, skipNBytes, transferTo`

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

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

- ## Constructor Details

  - ### SizedInputStream

    public SizedInputStream(InputStream is)
    Default constructor
    Parameters:
      `is` - the InputStream source

- ## Method Details

  - ### read

    public int read() throws IOException
    Specified by:
      `read` in class `InputStream`
    Throws:
      `IOException`

  - ### read

    public int read(byte[] b) throws IOException
    Overrides:
      `read` in class `InputStream`
    Throws:
      `IOException`

  - ### read

    public int read(byte[] b, int off, int len) throws IOException
    Overrides:
      `read` in class `InputStream`
    Throws:
      `IOException`

  - ### getSize

    public long getSize()
    Get read size
    Returns:
      the read size