Searched defs:pos (Results 1 - 25 of 40) sorted by relevance

12

/libcore/luni/src/main/java/java/io/
H A DStringBufferInputStream.java43 protected int pos; field in class:StringBufferInputStream
65 return count - pos;
78 return pos < count ? buffer.charAt(pos++) & 0xFF : -1;
90 int copylen = count - pos < byteCount ? count - pos : byteCount;
92 buffer[byteOffset + i] = (byte) this.buffer.charAt(pos + i);
94 pos += copylen;
103 pos = 0;
121 if (this.count - pos < charCoun
[all...]
H A DBufferedWriter.java45 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 DByteArrayInputStream.java36 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;
148 if (this.pos >= this.count) {
155 int copylen = this.count - pos < byteCount ? this.count - pos
[all...]
H A DStringReader.java33 private int pos; field in class:StringReader
91 markpos = pos;
126 if (pos != count) {
127 return str.charAt(pos++);
152 if (pos == this.count) {
155 int end = pos + count > this.count ? this.count : pos + count;
156 str.getChars(pos, end, buffer, offset);
157 int read = end - pos;
158 pos
[all...]
H A DBufferedInputStream.java63 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 DCharArrayReader.java36 protected int pos; field in class:CharArrayReader
87 this.pos = offset;
142 markedPos = pos;
179 if (pos == count) {
182 return buf[pos++];
202 if (pos < this.count) {
203 int bytesRead = pos + count > this.count ? this.count - pos : count;
204 System.arraycopy(this.buf, pos, buffer, offset, bytesRead);
205 pos
[all...]
H A DPushbackInputStream.java40 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);
173 if (pos < buf.length) {
174 copyLength = (buf.length - pos >= byteCount) ? byteCount : buf.length - pos;
175 System.arraycopy(buf, pos, buffe
[all...]
H A DPushbackReader.java40 int pos; field in class:PushbackReader
53 pos = 1;
73 pos = size;
140 if (pos < buf.length) {
141 return buf[pos++];
181 if (pos < buf.length) {
182 copyLength = (buf.length - pos >= count) ? count : buf.length
183 - pos;
184 System.arraycopy(buf, pos, buffer, newOffset, copyLength);
188 pos
[all...]
/libcore/luni/src/main/java/libcore/io/
H A DStrictLineReader.java53 * 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 DOldFormatTest.java32 FieldPosition pos) {
39 public Object parseObject(String source, ParsePosition pos) { argument
31 format(Object obj, StringBuffer toAppendTo, FieldPosition pos) argument
H A DOldDateFormatTest.java40 public Date parse(String source, ParsePosition pos) { argument
/libcore/support/src/test/java/tests/support/
H A DSupport_ASimpleInputStream.java18 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 DSupport_ASimpleOutputStream.java18 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 DSupport_ASimpleReader.java18 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 DSupport_ASimpleWriter.java18 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 DSupport_StringReader.java28 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/crypto/src/main/java/org/conscrypt/
H A DSSLSocketInputStream.java40 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/main/java/java/sql/
H A DBlob.java47 * 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 DClob.java60 * @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 DManifestReader.java41 private int pos; field in class:ManifestReader
54 this.endOfMainSection = pos;
58 int mark = pos;
84 chunks.put(entryNameValue, new Manifest.Chunk(mark, pos));
85 mark = pos;
114 int mark = pos;
116 while (pos < buf.length) {
117 if (buf[pos++] != ':') {
121 String nameString = new String(buf, mark, pos - mark - 1, StandardCharsets.US_ASCII);
123 if (buf[pos
[all...]
/libcore/luni/src/main/native/
H A Dlibcore_icu_DateIntervalFormat.cpp58 FieldPosition pos = 0; local
60 formatter->format(&date_interval, s, pos, status);
/libcore/luni/src/main/java/javax/net/ssl/
H A DDistinguishedNameParser.java31 private int pos; field in class:DistinguishedNameParser
53 for (; pos < length && chars[pos] == ' '; pos++) {
55 if (pos == length) {
60 beg = pos;
63 pos++;
64 for (; pos < length && chars[pos] != '=' && chars[pos] !
[all...]
/libcore/luni/src/main/java/org/apache/harmony/security/x509/
H A DDNParser.java46 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/test/java/libcore/java/io/
H A DOldByteArrayInputStreamTest.java58 assertEquals(444, SubByteArrayInputStream.pos);
66 public static int mark, pos, count; field in class:OldByteArrayInputStreamTest.SubByteArrayInputStream
73 pos = super.pos;
/libcore/json/src/main/java/org/json/
H A DJSONTokener.java71 private int pos; field in class:JSONTokener
110 pos--;
116 while (pos < in.length()) {
117 int c = in.charAt(pos++);
126 if (pos == in.length()) {
130 char peek = in.charAt(pos);
134 pos++;
135 int commentEnd = in.indexOf("*/", pos);
139 pos = commentEnd + 2;
144 pos
[all...]

Completed in 800 milliseconds

12