src/test/java/ucar/geoapi/TestData.java
final byte[] content() throws IOException {
        final byte[] content = new byte[length];
        try (InputStream stream = TestData.class.getResourceAsStream(filename)) {
            int offset = 0, r, n;
            do {
                r = length - offset;
                n = stream.read(content, offset, r);
                if (n < 0) throw new EOFException(filename);
            } while (r != n);
            if (stream.read() >= 0) {
                throw new IOException("Unexpected file length.");
            }
        }
        return content;
    }
/**
     * Returns the full content of the test file as an array of bytes.
     *
     * @return the test file content.
     * @throws IOException if an error occurred while reading the test file.
     */
Returns the full content of the test file as an array of bytes.
@return the test file content.
@throws IOException if an error occurred while reading the test file.
Returns the full content of the test file as an array of bytes . @return the test file content . @throws IOException if an error occurred while reading the test file .
final byte[] content() throws IOException {
        final byte[] content = new byte[length];
        try (InputStream stream = TestData.class.getResourceAsStream(filename)) {
            int offset = 0, r, n;
            do {
                r = length - offset;
                n = stream.read(content, offset, r);
                if (n < 0) throw new EOFException(filename);
            } while (r != n);
            if (stream.read() >= 0) {
                throw new IOException("Unexpected file length.");
            }
        }
        return content;
    }
final byte [ ] content ( ) throws IOException { final byte [ ] content = new byte [ length ] ; try ( InputStream stream = TestData . class . getResourceAsStream ( filename ) ) { int offset = 0 , r , n ; do { r = length - offset ; n = stream . read ( content , offset , r ) ; if ( n < 0 ) throw new EOFException ( filename ) ; } while ( r != n ) ; if ( stream . read ( ) >= 0 ) { throw new IOException ( "Unexpected file length." ) ; } } return content ; }
Returns the full content of the test file as an array of bytes.
Returns the full content of the test file as an array of bytes .