Lines Matching refs:buf
141 assertNotNull(MockBufferedInputStream.buf);
142 MockBufferedInputStream.buf = null;
144 assertNotNull(MockBufferedInputStream.buf);
148 static byte[] buf;
152 buf = super.buf;
157 buf = super.buf;
191 BufferedInputStream buf = new BufferedInputStream(null, 5);
192 buf.close();
203 public int read(byte[] buf, int offset, int length) {
275 BufferedInputStream buf = new BufferedInputStream(
277 buf.mark(3);
279 int result = buf.read(bytes);
284 assertEquals("Assert 3:", 3, buf.read());
286 buf = new BufferedInputStream(new ByteArrayInputStream(new byte[] { 0,
288 buf.mark(3);
290 result = buf.read(bytes);
296 assertEquals("Assert 8:", 4, buf.read());
297 assertEquals("Assert 9:", -1, buf.read());
299 buf = new BufferedInputStream(new ByteArrayInputStream(new byte[] { 0,
301 buf.mark(Integer.MAX_VALUE);
302 buf.read();
303 buf.close();
329 byte[] buf = new byte[14];
330 in.read(buf, 0, 14); // Read greater than the buffer
331 assertTrue("Wrong block read data", new String(buf, 0, 14)
406 public int read(byte[] buf, int off, int len) throws IOException {
414 System.arraycopy(contents, pos, buf, off, toRead);
531 BufferedInputStream buf = new BufferedInputStream(null, 5);
532 buf.skip(10);
543 BufferedInputStream buf = new BufferedInputStream(null, 5);
544 assertEquals(0, buf.skip(0));