/libcore/luni/src/main/java/java/io/ |
H A D | StringBufferInputStream.java | 43 protected int pos; field in class:StringBufferInputStream 65 return count - pos; 78 return pos < count ? buffer.charAt(pos++) & 0xFF : -1; 111 int copylen = count - pos < length ? count - pos : length; 113 buffer[offset + i] = (byte) this.buffer.charAt(pos + i); 115 pos += copylen; 124 pos = 0; 142 if (this.count - pos < charCoun [all...] |
H A D | BufferedWriter.java | 45 private int pos; field in class:BufferedWriter 138 if (pos > 0) { 139 out.write(buf, 0, pos); 141 pos = 0; 191 if (pos == 0 && count >= this.buf.length) { 195 int available = this.buf.length - pos; 200 System.arraycopy(buffer, offset, this.buf, pos, available); 201 pos += available; 203 if (pos == this.buf.length) { 205 pos [all...] |
H A D | ByteArrayInputStream.java | 36 protected int pos; field in class:ByteArrayInputStream 77 pos = offset; 85 * @return {@code count - pos} 89 return count - pos; 115 mark = pos; 141 return pos < count ? buf[pos++] & 0xFF : -1; 170 if (this.pos >= this.count) { 177 int copylen = this.count - pos < length ? this.count - pos [all...] |
H A D | BufferedInputStream.java | 63 protected int pos; field in class:BufferedInputStream 114 return count - pos + localIn.available(); 140 if (markpos == -1 || (pos - markpos >= marklimit)) { 145 pos = 0; 166 pos -= markpos; 168 int bytesread = localIn.read(localBuf, pos, localBuf.length - pos); 169 count = bytesread <= 0 ? pos : pos + bytesread; 189 markpos = pos; [all...] |
H A D | BufferedReader.java | 49 * mark pos end</pre> 51 * last readable character. When {@code pos == end}, the buffer is empty and 54 * <p>Mark is the value pos will be set to on calls to {@link #reset}. Its 55 * value is in the range {@code [0...pos]}. If the mark is {@code -1}, the 58 * <p>MarkLimit limits the distance between the mark and the pos. When this 65 private int pos; field in class:BufferedReader 120 * the buffer still contains data; ie. if {@code pos < end}. 126 // assert(pos == end); 128 if (mark == -1 || (pos - mark >= markLimit)) { 133 pos [all...] |
H A D | CharArrayReader.java | 36 protected int pos; field in class:CharArrayReader 87 this.pos = offset; 142 markedPos = pos; 179 if (pos == count) { 182 return buf[pos++]; 213 if (pos < this.count) { 214 int bytesRead = pos + len > this.count ? this.count - pos : len; 215 System.arraycopy(this.buf, pos, buffer, offset, bytesRead); 216 pos [all...] |
H A D | PushbackInputStream.java | 40 protected int pos; field in class:PushbackInputStream 57 pos = 1; 81 pos = size; 89 return buf.length - pos + in.available(); 141 if (pos < buf.length) { 142 return (buf[pos++] & 0xFF); 183 if (pos < buf.length) { 184 copyLength = (buf.length - pos >= length) ? length : buf.length 185 - pos; 186 System.arraycopy(buf, pos, buffe [all...] |
H A D | PushbackReader.java | 40 int pos; field in class:PushbackReader 53 pos = 1; 73 pos = size; 140 if (pos < buf.length) { 141 return buf[pos++]; 192 if (pos < buf.length) { 193 copyLength = (buf.length - pos >= count) ? count : buf.length 194 - pos; 195 System.arraycopy(buf, pos, buffer, newOffset, copyLength); 199 pos [all...] |
H A D | StringReader.java | 33 private int pos; field in class:StringReader 91 markpos = pos; 126 if (pos != count) { 127 return str.charAt(pos++); 162 if (pos == this.count) { 165 int end = pos + len > this.count ? this.count : pos + len; 166 str.getChars(pos, end, buf, offset); 167 int read = end - pos; 168 pos [all...] |
/libcore/luni/src/main/java/libcore/io/ |
H A D | StrictLineReader.java | 53 * Buffered data is stored in {@code buf}. As long as no exception occurs, 0 <= pos <= end 54 * and the data in the range [pos, end) is buffered for reading. At end of input, if there is 55 * an unterminated line, we set end == -1, otherwise end == pos. If the underlying 56 * {@code InputStream} throws an {@code IOException}, end may remain as either pos or -1. 59 private int pos; field in class:StrictLineReader 159 // throw again if that happens; thus we need to handle end == -1 as well as end == pos. 160 if (pos >= end) { 164 for (int i = pos; i != end; ++i) { 166 int lineEnd = (i != pos && buf[i - 1] == CR) ? i - 1 : i; 167 String res = new String(buf, pos, lineEn [all...] |
/libcore/luni/src/test/java/libcore/java/text/ |
H A D | OldFormatTest.java | 32 FieldPosition pos) { 39 public Object parseObject(String source, ParsePosition pos) { argument 31 format(Object obj, StringBuffer toAppendTo, FieldPosition pos) argument
|
H A D | OldDateFormatTest.java | 40 public Date parse(String source, ParsePosition pos) { argument
|
/libcore/support/src/test/java/tests/support/ |
H A D | Support_ASimpleInputStream.java | 18 public int pos; field in class:Support_ASimpleInputStream 36 pos = 0; 41 pos = 0; 59 return len - pos; 67 if (pos < len) { 68 int res = buf[pos]; 69 pos++;
|
H A D | Support_ASimpleOutputStream.java | 18 public int pos; field in class:Support_ASimpleOutputStream 36 pos = 0; 82 if (pos < size) { 83 buf[pos] = (byte)(oneByte & 255); 84 pos++; 91 byte[] toReturn = new byte[pos]; 92 System.arraycopy(buf, 0, toReturn, 0, pos); 97 return new String(buf, 0, pos);
|
H A D | Support_ASimpleReader.java | 18 public int pos; field in class:Support_ASimpleReader 36 pos = 0; 52 return len > pos; 60 int available = len - pos; 63 System.arraycopy(buf, pos, dest, offset, readable); 64 pos += readable;
|
H A D | Support_ASimpleWriter.java | 18 public int pos; field in class:Support_ASimpleWriter 36 pos = 0; 63 System.arraycopy(src, offset, buf, pos, count); 64 pos += count; 66 pos = size; 72 byte[] toReturn = new byte[pos]; 73 System.arraycopy(buf, 0, toReturn, 0, pos); 78 return new String(buf, 0, pos);
|
H A D | Support_StringReader.java | 28 private int pos = 0; field in class:Support_StringReader 84 markpos = pos; 121 if (pos != count) { 122 return str.charAt(pos++); 154 if (pos == this.count) { 157 int end = pos + count > this.count ? this.count : pos 159 str.getChars(pos, end, buf, offset); 160 int read = end - pos; 161 pos [all...] |
/libcore/luni/src/main/java/java/sql/ |
H A D | Blob.java | 47 * offset {@code pos}, and returns them as a binary stream. 54 public InputStream getBinaryStream(long pos, long length) throws SQLException; argument 59 * @param pos 65 * at {@code pos} and is up to {@code length} bytes long. 69 public byte[] getBytes(long pos, int length) throws SQLException; argument 120 * @param pos 129 public OutputStream setBinaryStream(long pos) throws SQLException; argument 135 * @param pos 146 public int setBytes(long pos, byte[] theBytes) throws SQLException; argument 152 * @param pos 168 setBytes(long pos, byte[] theBytes, int offset, int len) argument [all...] |
H A D | Clob.java | 60 * @param pos 68 public String getSubString(long pos, int length) throws SQLException; argument 114 * @param pos 121 public OutputStream setAsciiStream(long pos) throws SQLException; argument 127 * @param pos 134 public Writer setCharacterStream(long pos) throws SQLException; argument 140 * @param pos 148 public int setString(long pos, String str) throws SQLException; argument 154 * @param pos 166 public int setString(long pos, Strin argument 193 getCharacterStream(long pos, long length) argument [all...] |
/libcore/luni/src/main/java/java/util/jar/ |
H A D | InitManifest.java | 31 private int pos; field in class:InitManifest 57 int mark = pos; 83 chunks.put(entryNameValue, new Manifest.Chunk(mark, pos)); 84 mark = pos; 92 return pos; 113 int mark = pos; 115 while (pos < buf.length) { 116 if (buf[pos++] != ':') { 120 String name = new String(buf, mark, pos - mark - 1, Charsets.US_ASCII); 122 if (buf[pos [all...] |
/libcore/luni/src/main/java/libcore/net/http/ |
H A D | HeaderParser.java | 35 int pos = 0; 36 while (pos < value.length()) { 37 int tokenStart = pos; 38 pos = skipUntil(value, pos, "=,"); 39 String directive = value.substring(tokenStart, pos).trim(); 41 if (pos == value.length() || value.charAt(pos) == ',') { 42 pos++; // consume ',' (if necessary) 47 pos 125 skipUntil(String input, int pos, String characters) argument 138 skipWhitespace(String input, int pos) argument [all...] |
/libcore/luni/src/main/java/javax/net/ssl/ |
H A D | DistinguishedNameParser.java | 31 private int pos; field in class:DistinguishedNameParser 50 for (; pos < length && chars[pos] == ' '; pos++) { 52 if (pos == length) { 57 beg = pos; 60 pos++; 61 for (; pos < length && chars[pos] != '=' && chars[pos] ! [all...] |
/libcore/luni/src/main/java/org/apache/harmony/security/x509/ |
H A D | DNParser.java | 46 private int pos; field in class:DNParser 74 for (; pos < chars.length && chars[pos] == ' '; pos++) { 76 if (pos == chars.length) { 81 beg = pos; 84 pos++; 85 for (; pos < chars.length && chars[pos] != '=' && chars[pos] ! [all...] |
/libcore/luni/src/main/java/org/apache/harmony/xnet/provider/jsse/ |
H A D | SSLSocketInputStream.java | 40 private int pos; field in class:SSLSocketInputStream 81 return end - pos; 105 while (pos == end) { 114 return buffer[pos++] & 0xFF; 142 if (BUFFER_SIZE - (end - pos) < length) { 156 System.arraycopy(buffer, pos, buffer, 0, end-pos); 157 end -= pos; 158 pos = 0;
|
/libcore/luni/src/test/java/libcore/java/io/ |
H A D | OldByteArrayInputStreamTest.java | 58 assertEquals(444, SubByteArrayInputStream.pos); 66 public static int mark, pos, count; field in class:OldByteArrayInputStreamTest.SubByteArrayInputStream 73 pos = super.pos;
|