/libcore/ojluni/src/test/java/util/stream/test/org/openjdk/tests/java/util/stream/ |
H A D | CountLargeTest.java | 44 long count = LongStream.range(0, EXPECTED_LARGE_COUNT) 45 .mapToObj(e -> null).count(); 47 assertEquals(count, EXPECTED_LARGE_COUNT); 51 long count = LongStream.range(0, EXPECTED_LARGE_COUNT) 52 .mapToInt(e -> 0).count(); 54 assertEquals(count, EXPECTED_LARGE_COUNT); 58 long count = LongStream.range(0, EXPECTED_LARGE_COUNT) 59 .count(); 61 assertEquals(count, EXPECTED_LARGE_COUNT); 65 long count [all...] |
/libcore/support/src/test/java/tests/support/ |
H A D | Support_StringReader.java | 30 private int count; field in class:Support_StringReader 43 this.count = str.length(); 121 if (pos != count) { 131 * Reads at most <code>count</code> characters from this StringReader and 140 * @param count 148 public int read(char buf[], int offset, int count) throws IOException { argument 150 if (0 <= offset && offset <= buf.length && 0 <= count 151 && count <= buf.length - offset) { 154 if (pos == this.count) { 157 int end = pos + count > thi 228 skip(long count) argument [all...] |
H A D | Streams.java | 39 int count; 40 while ((count = source.read(buffer)) != -1) { 41 out.write(buffer, 0, count); 52 int count; 53 while ((count = fileReader.read(buffer)) != -1) { 54 out.write(buffer, 0, count);
|
H A D | ThrowingReader.java | 45 @Override public int read(char[] buf, int offset, int count) argument 50 count = Math.min(count, (throwAt - total)); 53 int returned = super.read(buf, offset, count);
|
H A D | Support_StringWriter.java | 99 * Writes <code>count</code> characters starting at <code>offset</code> 106 * @param count 110 * If offset or count are outside of bounds. 113 public void write(char[] buf, int offset, int count) { argument 115 if (0 <= offset && offset <= buf.length && 0 <= count 116 && count <= buf.length - offset) { 118 this.buf.append(buf, offset, count); 157 * Writes <code>count</code> number of characters starting at 165 * @param count 169 * If offset or count ar 172 write(String str, int offset, int count) argument [all...] |
/libcore/ojluni/src/main/java/java/io/ |
H A D | BufferedOutputStream.java | 47 * <tt>buf[0]</tt> through <tt>buf[count-1]</tt> contain valid 50 protected int count; field in class:BufferedOutputStream 81 if (count > 0) { 82 out.write(buf, 0, count); 83 count = 0; 94 if (count >= buf.length) { 97 buf[count++] = (byte)b; 125 if (len > buf.length - count) { 128 System.arraycopy(b, off, buf, count, len); 129 count [all...] |
H A D | ByteArrayOutputStream.java | 55 protected int count; field in class:ByteArrayOutputStream 135 ensureCapacity(count + 1); 136 buf[count] = (byte) b; 137 count += 1; 153 ensureCapacity(count + len); 154 System.arraycopy(b, off, buf, count, len); 155 count += len; 161 * stream's write method using <code>out.write(buf, 0, count)</code>. 167 out.write(buf, 0, count); 171 * Resets the <code>count</cod [all...] |
H A D | CharArrayWriter.java | 52 protected int count; field in class:CharArrayWriter 80 int newcount = count + 1; 84 buf[count] = (char)c; 85 count = newcount; 103 int newcount = count + len; 107 System.arraycopy(c, off, buf, count, len); 108 count = newcount; 120 int newcount = count + len; 124 str.getChars(off, off + len, buf, count); 125 count [all...] |
H A D | ByteArrayInputStream.java | 49 * through <code>buf[count-1]</code> are the 59 * and not larger than the value of <code>count</code>. 89 protected int count; field in class:ByteArrayInputStream 98 * of <code>count</code> is the length of 106 this.count = buf.length; 114 * of <code>count</code> is the minimum of <code>offset+length</code> 126 this.count = Math.min(offset + length, buf.length); 144 return (pos < count) ? (buf[pos++] & 0xff) : -1; 150 * If <code>pos</code> equals <code>count</code>, 154 * <code>len</code> and <code>count [all...] |
H A D | StringBufferInputStream.java | 65 protected int count; field in class:StringBufferInputStream 74 count = s.length(); 92 return (pos < count) ? (buffer.charAt(pos++) & 0xFF) : -1; 118 if (pos >= count) { 122 int avail = count - pos; 150 if (n > count - pos) { 151 n = count - pos; 161 * @return the value of <code>count - pos</code>, which is the 165 return count - pos;
|
H A D | CharArrayReader.java | 49 protected int count; field in class:CharArrayReader 58 this.count = buf.length; 85 this.count = Math.min(offset + length, buf.length); 103 if (pos >= count) 130 if (pos >= count) { 134 int avail = count - pos; 164 long avail = count - pos; 186 return (count - pos) > 0;
|
H A D | DataInputStream.java | 198 int count = in.read(b, off + n, len - n); 199 if (count < 0) 201 n += count; 603 int count = 0; 608 while (count < utflen) { 609 c = (int) bytearr[count] & 0xff; 611 count++; 615 while (count < utflen) { 616 c = (int) bytearr[count] & 0xff; 620 count [all...] |
/libcore/ojluni/src/main/java/java/lang/ |
H A D | AbstractStringBuilder.java | 55 * The count is the number of characters used. 57 int count; field in class:AbstractStringBuilder 73 * Returns the length (character count). 80 return count; 176 if (count < value.length) { 177 value = Arrays.copyOf(value, count); 211 if (count < newLength) { 212 Arrays.fill(value, count, newLength, '\0'); 215 count = newLength; 237 if ((index < 0) || (index >= count)) [all...] |
H A D | StringIndexOutOfBoundsException.java | 94 StringIndexOutOfBoundsException(String s, int offset, int count) { argument 95 this(s.length(), offset, count); 103 int count) { 105 + "; regionLength=" + count); 102 StringIndexOutOfBoundsException(int sourceLength, int offset, int count) argument
|
H A D | ArrayIndexOutOfBoundsException.java | 82 int count) { 84 + "; regionLength=" + count); 81 ArrayIndexOutOfBoundsException(int sourceLength, int offset, int count) argument
|
/libcore/luni/src/main/java/org/w3c/dom/ |
H A D | CharacterData.java | 69 * @param count The number of 16-bit units to extract. 71 * <code>count</code> exceeds the <code>length</code>, then all 16-bit 76 * <code>data</code>, or if the specified <code>count</code> is 82 int count) 114 * @param count The number of 16-bit units to delete. If the sum of 115 * <code>offset</code> and <code>count</code> exceeds 121 * <code>data</code>, or if the specified <code>count</code> is 126 int count) 133 * @param count The number of 16-bit units to replace. If the sum of 134 * <code>offset</code> and <code>count</cod 81 substringData(int offset, int count) argument 125 deleteData(int offset, int count) argument 148 replaceData(int offset, int count, String arg) argument [all...] |
/libcore/ojluni/src/main/java/java/util/ |
H A D | IntSummaryStatistics.java | 30 * A state object for collecting statistics such as count, min, max, sum, and 51 * This computes, in a single pass, the count of people, as well as the minimum, 65 private long count; field in class:IntSummaryStatistics 71 * Construct an empty instance with zero count, zero sum, 84 ++count; 97 count += other.count; 104 * Returns the count of values recorded. 106 * @return the count of values 109 return count; [all...] |
H A D | DoubleSummaryStatistics.java | 30 * A state object for collecting statistics such as count, min, max, sum, and 51 * This computes, in a single pass, the count of people, as well as the minimum, 63 private long count; field in class:DoubleSummaryStatistics 71 * Construct an empty instance with zero count, zero sum, 84 ++count; 99 count += other.count; 119 * Return the count of values recorded. 121 * @return the count of values 124 return count; [all...] |
H A D | LongSummaryStatistics.java | 31 * A state object for collecting statistics such as count, min, max, sum, and 52 * This computes, in a single pass, the count of people, as well as the minimum, 66 private long count; field in class:LongSummaryStatistics 72 * Construct an empty instance with zero count, zero sum, 95 ++count; 109 count += other.count; 116 * Returns the count of values recorded. 118 * @return the count of values 121 return count; [all...] |
/libcore/ojluni/src/main/java/java/util/concurrent/ |
H A D | CountDownLatch.java | 44 * <p>A {@code CountDownLatch} is initialized with a given <em>count</em>. 45 * The {@link #await await} methods block until the current count reaches 49 * -- the count cannot be reset. If you need a version that resets the 50 * count, consider using a {@link CyclicBarrier}. 54 * {@code CountDownLatch} initialized with a count of one serves as a 63 * the count to reach zero before proceeding, it simply prevents any 115 * count down in this way, instead use a {@link CyclicBarrier}.) 147 * <p>Memory consistency effects: Until the count reaches 160 * Uses AQS state to represent count. 165 Sync(int count) { argument 199 CountDownLatch(int count) argument [all...] |
/libcore/ojluni/src/main/java/sun/net/www/ |
H A D | MeteredStream.java | 42 protected long count = 0; field in class:MeteredStream 72 count += n; 77 if (count - markedCount > markLimit) { 82 pi.updateProgress(count, expected); 91 if (count >= expected) { 107 if (count - markedCount > markLimit) { 153 long min = (n > expected - count) ? expected - count: n; 185 * mark the count to restore upon reset 187 markedCount = count; [all...] |
/libcore/ojluni/src/main/java/java/sql/ |
H A D | Array.java | 161 * specified <code>index</code> and containing up to <code>count</code> 172 * @param count the number of successive SQL array elements to retrieve 173 * @return an array containing up to <code>count</code> consecutive elements 181 Object getArray(long index, int count) throws SQLException; argument 186 * <code>index</code> and containing up to <code>count</code> 204 * @param count the number of successive SQL array elements to 209 * @return an array containing up to <code>count</code> 219 Object getArray(long index, int count, java.util.Map<String,Class<?>> map) argument 281 * <code>count</code> successive elements. This method uses 289 * up to <code>count</cod 307 getResultSet(long index, int count) argument 344 getResultSet(long index, int count, java.util.Map<String,Class<?>> map) argument [all...] |
/libcore/harmony-tests/src/test/java/org/apache/harmony/tests/java/util/jar/ |
H A D | JarInputStreamTest.java | 163 int count = 0; 164 while (count == 0 || entry != null) { 165 count++; 168 assertEquals(TOTAL_ENTRIES + 1, count); 180 int count = 0; 181 while (count == 0 || zipEntry != null) { 182 count++; 185 if (count == TEST_CLASS_INDEX + 1) { 189 if (count != TEST_CLASS_INDEX + 1) { 195 assertEquals(TOTAL_ENTRIES + 2, count); [all...] |
/libcore/luni/src/main/java/org/apache/harmony/xml/dom/ |
H A D | CharacterDataImpl.java | 46 public void deleteData(int offset, int count) throws DOMException { argument 47 buffer.delete(offset, offset + count); 78 public void replaceData(int offset, int count, String arg) argument 81 buffer.replace(offset, offset + count, arg); 91 public String substringData(int offset, int count) throws DOMException { argument 93 return buffer.substring(offset, offset + count);
|
/libcore/harmony-tests/src/test/java/org/apache/harmony/tests/java/util/ |
H A D | ScannerParseLargeFileBenchmarkTest.java | 46 private int count = 0; field in class:ScannerParseLargeFileBenchmarkTest.FakeLargeFile 54 if (count >= FILE_LENGTH) { 58 final int charsToRead = Math.min(FILE_LENGTH - count, length); 60 int contentIndex = count % CONTENT.length; 69 count += charsRead;
|