Class LimitedInputStream
- java.lang.Object
-
- java.io.InputStream
-
- org.apache.nemo.runtime.executor.data.LimitedInputStream
-
- All Implemented Interfaces:
java.io.Closeable
,java.lang.AutoCloseable
public final class LimitedInputStream extends java.io.InputStream
This class provide functionality to limit bytes read fromInputStream
. You need to wrap chained compression stream with this stream to prevent overreading inner stream.
-
-
Constructor Summary
Constructors Constructor Description LimitedInputStream(java.io.InputStream in, long limit)
Constructor.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description int
read()
-