final void checkAvailable(int pos, int k) throws EOFException {
        if (pos < 0) {
            throw new IllegalArgumentException("Negative pos! -> " + pos);
        }
        if ((size - pos) < k) {
            throw new EOFException("Cannot read " + k + " bytes!");
        }
    }
@Test(expected = EOFException.class)
    public void testCheckAvailable_EOF() throws Exception {
        in.checkAvailable(0, INIT_DATA.length + 1);
    }