/dalvik/libcore/xml/src/test/java/tests/api/org/xml/sax/support/ |
H A D | BrokenInputStream.java | 24 * IOException after having read a specified number of bytes. Used for 41 public int read() throws IOException { method in class:BrokenInputStream 47 return stream.read();
|
/dalvik/libcore/luni/src/test/java/tests/api/java/io/ |
H A D | BufferedReaderTest.java | 89 br.read(); 126 br.read(buf, 0, 500); 136 br.read(buf, 0, 1000); 150 in.read(new char[14], 0, 14); 152 assertTrue("Wrong chars", in.read() == (char) 6 153 && in.read() == (char) 7); 164 assertTrue("Wrong chars 2", in.read() == (char) 6 165 && in.read() == (char) 7); 186 * @tests java.io.BufferedReader#read() 190 method = "read", [all...] |
H A D | StringBufferInputStreamTest.java | 66 * @tests java.io.StringBufferInputStream#read() 71 method = "read", 75 // Test for method int java.io.StringBufferInputStream.read() 78 sbis.read(buf, 0, 5); 83 * @tests java.io.StringBufferInputStream#read() 88 method = "read", 92 // Test for method int java.io.StringBufferInputStream.read() 95 sbis.read(buf, 0, -1); 101 sbis.read(buf, -1, 1); 107 sbis.read(bu [all...] |
H A D | FilterInputStreamTest.java | 108 is.read(); 150 is.read(buf1, 0, bufSize); 152 is.read(buf1, 0, bufSize); 158 is.read(buf2, 0, bufSize); 167 is.read(buf1, 0, bufSize); 169 is.read(buf1, 0, bufSize); 171 is.read(buf2, 0, bufSize); 202 * @tests java.io.FilterInputStream#read() 206 method = "read", 210 int c = is.read(); [all...] |
H A D | InputStreamReaderTest.java | 62 // A ByteArrayInputStream that only returns a single byte per read 84 public int read() { method in class:InputStreamReaderTest.LimitedByteArrayInputStream 91 public int read(byte[] buffer, int offset, int length) { method in class:InputStreamReaderTest.LimitedByteArrayInputStream 144 * Class under test for int read() 149 method = "read", 153 assertEquals('T', (char) reader.read()); 154 assertEquals('h', (char) reader.read()); 155 assertEquals('i', (char) reader.read()); 156 assertEquals('s', (char) reader.read()); 157 assertEquals(' ', (char) reader.read()); [all...] |
H A D | PushbackReaderTest.java | 54 pbr.read(buf, 0, 5); 126 pbr.read(); 166 * @tests java.io.PushbackReader#read() 170 method = "read", 177 assertEquals("Wrong value read!", 66, tobj.read()); 180 tobj.read(); 186 // Test for method int java.io.PushbackReader.read() 189 pbr.read(); 190 c = (char) pbr.read(); [all...] |
H A D | PipedReaderTest.java | 152 preader.read(c, 0, 5); 156 preader.read(c, 0, 5); 182 preader.read(c, 0, 11); 184 assertEquals("Test 1: Wrong characters read. ", "Hello World", new String(c)); 194 * @tests java.io.PipedReader#read() 199 method = "read", 203 // Test for method int java.io.PipedReader.read() 211 c[i] = (char) preader.read(); 213 assertEquals("Test 1: Wrong characters read. ", "Hello World", new String(c)); 216 preader.read(); [all...] |
H A D | BufferedInputStreamTest.java | 64 is.read(); 95 // Ensure buffer gets filled by evaluating one read 96 is.read(); 103 is.read(); 105 // is.read should now throw an exception because it will have to 107 is.read(); 111 assertTrue("Exception should have been triggered by read()", 193 is.read(); 228 method = "read", 234 method = "read", [all...] |
H A D | PushbackInputStreamTest.java | 155 * @tests java.io.PushbackInputStream#read() 160 method = "read", 167 assertEquals("Test 1: Incorrect byte read;", 66, tobj.read()); 170 tobj.read(); 176 assertEquals("Test 3: Incorrect byte read;", 177 fileString.getBytes()[0], pis.read()); 181 * @tests java.io.PushbackInputStream#read(byte[], int, int) 186 method = "read", 194 tobj.read(bu [all...] |
H A D | CharArrayReaderTest.java | 91 assertEquals("Test 6: Incorrect character read;", 92 'W', cr.read()); 108 cr.read(); 109 fail("Failed to throw exception on read from closed stream"); 129 cr.read(); 132 'W', cr.read()); 159 * @tests java.io.CharArrayReader#read() 163 method = "read", 169 'H', cr.read()); 172 cr.read() [all...] |
H A D | InputStreamTest.java | 49 public int read() throws IOException { method in class:InputStreamTest.MockInputStream 139 * @tests java.io.InputStream#read(byte[]) 144 notes = "Verifies read(byte[]).", 145 method = "read", 150 notes = "Verifies ObjectInput.read(byte[]) since " + 152 "of read(byte[]) from InputStream.", 154 method = "read", 167 // Test 1: This read operation should complete without an error. 168 assertEquals("Test 1: Incorrect count of bytes read.", 169 is.read( [all...] |
/dalvik/libcore/luni/src/main/java/java/io/ |
H A D | LineNumberInputStream.java | 26 * When using {@code read}, line terminator sequences are always translated into 44 * {@code in}. Line numbers are counted for all data read from this stream. 77 * indicates how many bytes can be read before the mark is invalidated. 86 * the number of bytes that can be read from this stream before 108 * @return the byte read or -1 if the end of the filtered stream has been 115 public int read() throws IOException { method in class:LineNumberInputStream 118 currentChar = in.read(); 125 lastChar = in.read(); 139 * Returns the number of bytes actually read or -1 if no bytes have been 140 * read an 166 public int read(byte[] buffer, int offset, int length) throws IOException { method in class:LineNumberInputStream [all...] |
H A D | BufferedInputStream.java | 44 * The buffer containing the current bytes read from the target InputStream. 118 * Returns an estimated number of bytes that can be read or skipped without blocking for more 157 int result = localIn.read(localBuf); 183 int bytesread = localIn.read(localBuf, pos, localBuf.length - pos); 190 * indicates how many bytes can be read before a mark is invalidated. 197 * the number of bytes that can be read before the mark is 226 * @return the byte read or -1 if the end of the source stream has been 232 public synchronized int read() throws IOException { method in class:BufferedInputStream 265 * number of bytes actually read or -1 if no bytes were read an 288 public synchronized int read(byte[] buffer, int offset, int length) method in class:BufferedInputStream [all...] |
H A D | StreamTokenizer.java | 67 * token that has been read. When a single character is read, its value 262 int currentChar = peekChar == -2 ? read() : peekChar; 266 currentChar = read(); 285 if ((currentChar = read()) == '\n') { 286 currentChar = read(); 294 currentChar = read(); 297 currentChar = read(); 318 currentChar = read(); 342 currentChar = read(); 549 private int read() throws IOException { method in class:StreamTokenizer [all...] |
/dalvik/libcore/luni/src/main/java/org/apache/harmony/luni/net/ |
H A D | SocketInputStream.java | 30 * opened streams and coordinate read operations between threads. 40 * @param socket the socket to be read 59 public int read() throws IOException { method in class:SocketInputStream 61 int result = socket.read(buffer, 0, 1); 66 public int read(byte[] buffer) throws IOException { method in class:SocketInputStream 67 return read(buffer, 0, buffer.length); 71 public int read(byte[] buffer, int offset, int count) throws IOException { method in class:SocketInputStream 88 return socket.read(buffer, offset, count);
|
/dalvik/libcore/x-net/src/main/java/org/apache/harmony/xnet/provider/jsse/ |
H A D | ServerHello.java | 89 server_version[0] = (byte) in.read(); 90 server_version[1] = (byte) in.read(); 91 in.read(random, 0, 32); 94 in.read(session_id, 0, size); 95 byte b0 = (byte) in.read(); 96 byte b1 = (byte) in.read(); 98 compression_method = (byte) in.read();
|
H A D | ClientHello.java | 90 in.read(random, 0, 32); 91 int size = in.read(); 93 in.read(session_id, 0, size); 102 byte b0 = (byte) in.read(); 103 byte b1 = (byte) in.read(); 106 size = in.read(); 108 in.read(compression_methods, 0, size); 147 byte b0 = (byte) in.read(); 148 byte b1 = (byte) in.read(); 149 byte b2 = (byte) in.read(); [all...] |
/dalvik/libcore/archive/src/main/java/java/util/zip/ |
H A D | CheckedInputStream.java | 25 * same time as the data, on which the checksum is computed, is read from a 58 public int read() throws IOException { method in class:CheckedInputStream 59 int x = in.read(); 69 * updated with the bytes read. 72 * the byte array in which to store the bytes read. 74 * the initial position in {@code buf} to store the bytes read 78 * @return the number of bytes actually read or {@code -1} if arrived at the 84 public int read(byte[] buf, int off, int nbytes) throws IOException { method in class:CheckedInputStream 85 int x = in.read(buf, off, nbytes); 93 * Returns the checksum calculated on the stream read s [all...] |
/dalvik/libcore/nio/src/test/java/org/apache/harmony/nio/tests/java/nio/channels/ |
H A D | SourceChannelTest.java | 41 method = "read", 89 * @tests java.nio.channels.Pipe.SourceChannel#read(ByteBuffer) 94 method = "read", 98 // if anything can read, read method will not block 100 int count = source.read(ByteBuffer.allocate(10)); 105 * @tests java.nio.channels.Pipe.SourceChannel#read(ByteBuffer) 110 method = "read", 116 source.read(nullBuf); 124 * @tests java.nio.channels.Pipe.SourceChannel#read(ByteBuffe [all...] |
/dalvik/libcore/luni/src/test/java/org/apache/harmony/luni/tests/java/io/ |
H A D | ReaderTest.java | 54 mockReader.read(charBuffer); 71 method = "read", 76 // If the charBuffer has a capacity of 0, then the number of char read 83 int result = mockReader.read(charBuffer); 86 mockReader.read(destBuffer); 100 method = "read", 112 int result = mockReader.read(charBuffer); 119 mockReader.read(destBuffer); 126 assertEquals("Wrong return value!", 4, simple.read(buf)); 128 assertEquals("Wrong stuff read!", "Bl 355 public int read(char[] buf, int offset, int count) throws IOException { method in class:ReaderTest.MockReader [all...] |
/dalvik/libcore/archive/src/test/java/java/util/zip/ |
H A D | DeflaterOutputStreamTest.java | 33 assertEquals(1, in.read()); 34 assertEquals(2, in.read()); 35 assertEquals(3, in.read()); 41 in.read(); 53 * stream is read, that read will fail when no bytes are available. Failing 57 * the dry read to block indefinitely.
|
/dalvik/libcore/luni/src/main/java/org/apache/harmony/luni/internal/net/www/protocol/ftp/ |
H A D | FtpURLInputStream.java | 40 public int read() throws IOException { method in class:FtpURLInputStream 41 return is.read(); 45 public int read(byte[] buf, int off, int nbytes) throws IOException { method in class:FtpURLInputStream 46 return is.read(buf, off, nbytes);
|
/dalvik/libcore/nio/src/main/java/java/nio/channels/ |
H A D | DatagramChannel.java | 39 * invoking {@code read} or {@code write}, a connected channel is required. 41 * Datagram channels are thread-safe; only one thread can read or write at the 78 * Gets the valid operations of this channel. Datagram channels support read 112 * This method can be called at any time without affecting the read and 145 * This method can be called at any time without affecting the read and 167 * another thread that has started a read operation on the channel. 243 * behavior as the {@code read} method in the {@link ReadableByteChannel} 246 * @see java.nio.channels.ReadableByteChannel#read(java.nio.ByteBuffer) 249 * @return a non-negative number as the number of bytes read, or -1 as the 250 * read operatio 265 public abstract int read(ByteBuffer target) throws IOException; method in class:DatagramChannel 305 public abstract long read(ByteBuffer[] targets, int offset, int length) method in class:DatagramChannel 337 public synchronized final long read(ByteBuffer[] targets) method in class:DatagramChannel [all...] |
H A D | SocketChannel.java | 45 * is used for the input side of a channel and subsequent read operations return 46 * -1, which means end of stream. If another thread is blocked in a read 47 * operation when the shutdown occurs, the read will end without effect and 54 * Socket channels are thread-safe, no more than one thread can read or write at 57 * processing, calls to {@code read} and {@code write} will block. 128 * connect, read and write operation, so this method returns 172 * This method can be called at any moment and can block other read and 219 * read} and {@code write} operations while connecting. 243 * The maximum number of bytes that will be read is the remaining number of 247 * The call may block if other threads are also attempting to read fro 270 public abstract int read(ByteBuffer target) throws IOException; method in class:SocketChannel 307 public abstract long read(ByteBuffer[] targets, int offset, int length) method in class:SocketChannel 339 public synchronized final long read(ByteBuffer[] targets) method in class:SocketChannel [all...] |
/dalvik/libcore/sql/src/main/java/SQLite/ |
H A D | Blob.java | 92 * @return byte read 95 public int read() throws IOException { method in class:BlobR 97 int n = blob.read(b, 0, pos, b.length); 108 * @return number of bytes read 111 public int read(byte b[]) throws IOException { method in class:BlobR 112 int n = blob.read(b, 0, pos, b.length); 124 * @param len length to be read 125 * @return number of bytes read 128 public int read(byte b[], int off, int len) throws IOException { method in class:BlobR 138 int n = blob.read( 302 native int read(byte[] b, int off, int pos, int len) throws IOException; method in class:Blob [all...] |