Java FilterInputStream Class

Java FilterInputStream class implements the InputStream. It contains different sub classes as BufferedInputStream, DataInputStream for providing additional functionality. So it is less used individually.

Java FilterInputStream class declaration

public class FilterInputStream extends InputStream

Java ByteArrayInputStream class constructors

Method Description
int available() It is used to return an estimate number of bytes that can be read from the input stream.
int read() It is used to read the next byte of data from the input stream.
int read(byte[] ary, int off, int len) It is used to read up to len bytes of data from an array of bytes in the input stream.
boolean markSupported() It is used to test if the input stream support mark and reset method.
long skip(long x) It is used to skip over and discards n bytes of data from the input stream.
void mark(int readAheadLimit) It is used to mark the current position in the input stream.
void reset() It is used to reset the input stream.
void close() It is used to close the input stream.

Example of FilterInputStream class

Flash Soon


Output:



Advertisement

Copyright ©2017 Design& develop