Package com.webmethods.caf.common.io
Class LimitedInputStream
java.lang.Object
java.io.InputStream
java.io.FilterInputStream
com.webmethods.caf.common.io.LimitedInputStream
- All Implemented Interfaces:
Closeable
,AutoCloseable
Filter input stream which allows only a specified number of bytes
to be read (as if the stream only contained the specified number of bytes).
-
Field Summary
FieldsModifier and TypeFieldDescriptionprotected int
protected int
protected int
Fields inherited from class java.io.FilterInputStream
in
-
Constructor Summary
Constructors -
Method Summary
Methods inherited from class java.io.FilterInputStream
close, markSupported
Methods inherited from class java.io.InputStream
nullInputStream, readAllBytes, readNBytes, readNBytes, skipNBytes, transferTo
-
Field Details
-
m_index
protected int m_index -
m_limit
protected int m_limit -
m_mark
protected int m_mark
-
-
Constructor Details
-
LimitedInputStream
-
-
Method Details
-
read
- Overrides:
read
in classFilterInputStream
- Throws:
IOException
-
read
- Overrides:
read
in classFilterInputStream
- Throws:
IOException
-
read
- Overrides:
read
in classFilterInputStream
- Throws:
IOException
-
skip
- Overrides:
skip
in classFilterInputStream
- Throws:
IOException
-
available
- Overrides:
available
in classFilterInputStream
- Throws:
IOException
-
mark
public void mark(int readlimit) - Overrides:
mark
in classFilterInputStream
-
reset
- Overrides:
reset
in classFilterInputStream
- Throws:
IOException
-