Class OriginSeekInputStream

All Implemented Interfaces:
RepositionableStream, Closeable, AutoCloseable

public class OriginSeekInputStream extends SeekInputStream
Alters the origin of some other SeekInputStream. This class allows you to completely ignore everything in the underlying stream before a specified position, the origin position.

With the exception of position() and position(long), all of the methods in this class simply delegate to the underlying input stream. The position methods adjust the position of the underlying stream relative to the origin specified at construction time.

Author:
pjack
  • Constructor Details

    • OriginSeekInputStream

      public OriginSeekInputStream(SeekInputStream input, long origin) throws IOException
      Constructor.
      Parameters:
      input - the underlying stream
      origin - the origin position
      Throws:
      IOException - if an IO error occurs
  • Method Details