Class SkipShieldingInputStream
- java.lang.Object
-
- java.io.InputStream
-
- java.io.FilterInputStream
-
- org.apache.commons.compress.utils.SkipShieldingInputStream
-
- All Implemented Interfaces:
java.io.Closeable,java.lang.AutoCloseable
@Deprecated public class SkipShieldingInputStream extends java.io.FilterInputStreamDeprecated.No longer used.A wrapper that overwritesskip(long)and delegates toFilterInputStream.read()instead.Some implementations of
InputStreamimplementInputStream.skip(long)in a way that throws an exception if the stream is not seekable -System.inis known to behave that way. For such a stream it is impossible to invoke skip at all and you have to read from the stream (and discard the data read) instead. Skipping is potentially much faster than reading so we do want to invokeskipwhen possible. We provide this class so you can wrap your ownInputStreamin it if you encounter problems withskipthrowing an exception.- Since:
- 1.17
-
-
Constructor Summary
Constructors Constructor Description SkipShieldingInputStream(java.io.InputStream in)Deprecated.
-
Method Summary
All Methods Instance Methods Concrete Methods Deprecated Methods Modifier and Type Method Description longskip(long n)Deprecated.-
Methods inherited from class java.io.FilterInputStream
available, close, mark, markSupported, read, read, read, reset
-
-