Class ByteRangeCapturingInputStream

  • All Implemented Interfaces:
    com.amazonaws.internal.MetricAware, com.amazonaws.internal.Releasable, Closeable, AutoCloseable

    public class ByteRangeCapturingInputStream
    extends com.amazonaws.internal.SdkFilterInputStream
    FilterInputStream that captures a range of bytes from a wrapped input stream.
    • Constructor Detail

      • ByteRangeCapturingInputStream

        public ByteRangeCapturingInputStream​(InputStream in,
                                             long startingPosition,
                                             long endingPosition)
    • Method Detail

      • getBlock

        public byte[] getBlock()
      • read

        public int read()
                 throws IOException
        Overrides:
        read in class com.amazonaws.internal.SdkFilterInputStream
        Throws:
        IOException
      • mark

        public void mark​(int readlimit)
        Overrides:
        mark in class com.amazonaws.internal.SdkFilterInputStream
      • reset

        public void reset()
                   throws IOException
        Overrides:
        reset in class com.amazonaws.internal.SdkFilterInputStream
        Throws:
        IOException
      • read

        public int read​(byte[] b,
                        int off,
                        int len)
                 throws IOException
        Overrides:
        read in class com.amazonaws.internal.SdkFilterInputStream
        Throws:
        IOException