@Override public DefaultDataBuffer read(byte[] destination) { Assert.notNull(destination, "Byte array must not be null"); read(destination, 0, destination.length); return this; }
@Override public int read(byte[] bytes, int off, int len) throws IOException { int available = available(); if (available > 0) { len = Math.min(len, available); DefaultDataBuffer.this.read(bytes, off, len); return len; } else { return -1; } } }
@Override public DefaultDataBuffer read(byte[] destination) { Assert.notNull(destination, "Byte array must not be null"); read(destination, 0, destination.length); return this; }
@Override public int read() { return available() > 0 ? DefaultDataBuffer.this.read() & 0xFF : -1; }
@Override public int read() { return available() > 0 ? DefaultDataBuffer.this.read() & 0xFF : -1; }
@Override public int read(byte[] bytes, int off, int len) throws IOException { int available = available(); if (available > 0) { len = Math.min(len, available); DefaultDataBuffer.this.read(bytes, off, len); return len; } else { return -1; } } }
@Override public DefaultDataBuffer read(byte[] destination) { Assert.notNull(destination, "'destination' must not be null"); read(destination, 0, destination.length); return this; }
@Override public DefaultDataBuffer read(byte[] destination) { Assert.notNull(destination, "Byte array must not be null"); read(destination, 0, destination.length); return this; }
@Override public int read() { return available() > 0 ? DefaultDataBuffer.this.read() & 0xFF : -1; }
@Override public int read(byte[] bytes, int off, int len) throws IOException { int available = available(); if (available > 0) { len = Math.min(len, available); DefaultDataBuffer.this.read(bytes, off, len); return len; } else { return -1; } } }
@Override public int read() { return available() > 0 ? DefaultDataBuffer.this.read() & 0xFF : -1; }
@Override public int read(byte[] bytes, int off, int len) throws IOException { int available = available(); if (available > 0) { len = Math.min(len, available); DefaultDataBuffer.this.read(bytes, off, len); return len; } else { return -1; } } }