public abstract void readFully (byte[] b) throws IOException

Reads some bytes from an input stream and stores them into the buffer array b. The number of bytes read is equal to the length of b.

This method blocks until one of the following conditions occurs:

If b is null, a NullPointerException is thrown. If b.length is zero, then no bytes are read. Otherwise, the first byte read is stored into element b[0], the next one into b[1], and so on. If an exception is thrown from this method, then it may be that some but not all bytes of b have been updated with data from the input stream.

Parameters:
b    the buffer into which the data is read.

Exceptions:
NullPointerException    if b is null.
EOFException    if this stream reaches the end before reading all the bytes.
IOException    if an I/O error occurs.