public int available() throws IOException { checkClosed(); return (buf != null ? len - at : 0); }
public int available() throws IOException { checkClosed(); return ( buf != null ? len - at : 0 ); }
public int read(byte[] buf, int off, int siz) throws IOException { checkClosed(); int got = 0; boolean didReadSomething = false; while (got < siz && (didReadSomething = gotBuf())) { buf[off + got++] = this.buf[at++]; } return got == 0 && !didReadSomething ? -1 : got; }
public int read(byte[] buf, int off, int siz) throws IOException { checkClosed(); int got = 0; while( got < siz && gotBuf() ) { buf[off+got++] = this.buf[at++]; } return got; }
public int read() throws IOException { checkClosed(); return gotBuf() ? buf[at++] : -1; }
public int read() throws IOException { checkClosed(); return gotBuf() ? buf[at++] : -1; }
public int available() throws IOException { checkClosed(); return ( buf != null ? len - at : 0 ); }
public int available() throws IOException { checkClosed(); return ( buf != null ? len - at : 0 ); }
public int read(byte[] buf, int off, int siz) throws IOException { checkClosed(); int got = 0; while( got < siz && gotBuf() ) { buf[off+got++] = this.buf[at++]; } return got; }
public int read(byte[] buf, int off, int siz) throws IOException { checkClosed(); int got = 0; while( got < siz && gotBuf() ) { buf[off+got++] = this.buf[at++]; } return got; }
public int read() throws IOException { checkClosed(); return gotBuf() ? buf[at++] : -1; }
public int read() throws IOException { checkClosed(); return gotBuf() ? buf[at++] : -1; }