/** * Invokes the delegate's <code>read(byte[] data, int, int)</code> method. * * @param data the buffer to read the bytes into * @param offset The start offset * @param length The number of bytes to read * @throws EOFException if an end of file is reached unexpectedly * @throws IOException if an I/O error occurs */ @Override public void readFully( final byte[] data, final int offset, final int length ) throws IOException, EOFException { int remaining = length; while( remaining > 0 ) { final int location = offset + length - remaining; final int count = read( data, location, remaining ); if (EOF == count) { throw new EOFException(); } remaining -= count; } }
/** @see java.io.DataInput#readFully(byte[], int, int) */ public void readFully( byte[] data, int offset, int length ) throws IOException, EOFException { int remaining = length; while( remaining > 0 ) { int location = offset + ( length - remaining ); int count = read( data, location, remaining ); if( -1 == count ) { throw new EOFException(); } remaining -= count; } }
/** * Invokes the delegate's <code>read(byte[] data, int, int)</code> method. * * @param data the buffer to read the bytes into * @param offset The start offset * @param length The number of bytes to read * @throws EOFException if an end of file is reached unexpectedly * @throws IOException if an I/O error occurs */ public void readFully( final byte[] data, final int offset, final int length ) throws IOException, EOFException { int remaining = length; while( remaining > 0 ) { final int location = offset + length - remaining; final int count = read( data, location, remaining ); if (EOF == count) { throw new EOFException(); } remaining -= count; } }
/** * Invokes the delegate's <code>read(byte[] data, int, int)</code> method. * * @param data the buffer to read the bytes into * @param offset The start offset * @param length The number of bytes to read * @throws EOFException if an end of file is reached unexpectedly * @throws IOException if an I/O error occurs */ public void readFully( byte[] data, int offset, int length ) throws IOException, EOFException { int remaining = length; while( remaining > 0 ) { int location = offset + length - remaining; int count = read( data, location, remaining ); if( -1 == count ) { throw new EOFException(); } remaining -= count; } }
/** * Invokes the delegate's <code>read(byte[] data, int, int)</code> method. * * @param data the buffer to read the bytes into * @param offset The start offset * @param length The number of bytes to read * @throws EOFException if an end of file is reached unexpectedly * @throws IOException if an I/O error occurs */ public void readFully( byte[] data, int offset, int length ) throws IOException, EOFException { int remaining = length; while( remaining > 0 ) { int location = offset + ( length - remaining ); int count = read( data, location, remaining ); if( -1 == count ) { throw new EOFException(); } remaining -= count; } }
/** * Invokes the delegate's <code>read(byte[] data, int, int)</code> method. * * @param data the buffer to read the bytes into * @param offset The start offset * @param length The number of bytes to read * @throws EOFException if an end of file is reached unexpectedly * @throws IOException if an I/O error occurs */ public void readFully( byte[] data, int offset, int length ) throws IOException, EOFException { int remaining = length; while( remaining > 0 ) { int location = offset + ( length - remaining ); int count = read( data, location, remaining ); if( -1 == count ) { throw new EOFException(); } remaining -= count; } }
/** * Invokes the delegate's <code>read(byte[] data, int, int)</code> method. * * @param data the buffer to read the bytes into * @param offset The start offset * @param length The number of bytes to read * @throws EOFException if an end of file is reached unexpectedly * @throws IOException if an I/O error occurs */ public void readFully( byte[] data, int offset, int length ) throws IOException, EOFException { int remaining = length; while( remaining > 0 ) { int location = offset + length - remaining; int count = read( data, location, remaining ); if( -1 == count ) { throw new EOFException(); } remaining -= count; } }
/** * Invokes the delegate's <code>read(byte[] data, int, int)</code> method. * * @param data the buffer to read the bytes into * @param offset The start offset * @param length The number of bytes to read * @throws EOFException if an end of file is reached unexpectedly * @throws IOException if an I/O error occurs */ @Override public void readFully( final byte[] data, final int offset, final int length ) throws IOException, EOFException { int remaining = length; while( remaining > 0 ) { final int location = offset + length - remaining; final int count = read( data, location, remaining ); if (EOF == count) { throw new EOFException(); } remaining -= count; } }