private void skipPrevious() { // Requires 0<codePointStart. codePointLimit=codePointStart; codePointStart=str.offsetByCodePoints(codePointStart, -1); } private int previousCC() { // Returns 0 if there is no previous character.
public int offsetByCodePoints(int index, int codePointOffset) { return delegator.offsetByCodePoints(index, codePointOffset); }
public int offsetByCodePoints(int index, int codePointOffset) { return builder.offsetByCodePoints(index, codePointOffset); }
public int offsetByCodePoints(int index, int codePointOffset) { return sb.offsetByCodePoints(index, codePointOffset); }
int backwardNumCodePoints(int n) { int length = oldBuffer.length(); int beyond = pos - length; if(beyond > 0) { if(beyond >= n) { // Not back far enough to re-enter the oldBuffer. pos -= n; return n; } else { // Back out all beyond-oldBuffer code points and re-enter the buffer. pos = oldBuffer.offsetByCodePoints(length, beyond - n); return beyond; } } else { // Go backwards from inside the oldBuffer. pos = oldBuffer.offsetByCodePoints(pos, -n); return 0; } }
@Override @JTranscAsync public synchronized int offsetByCodePoints(int index, int codePointOffset) { return super.offsetByCodePoints(index, codePointOffset); }
} else if ((cp == '>') && (tag.lastIndexOf("\\") != tag.offsetByCodePoints(tag.length(), -1))) { num++; Xtag oneTag = new Xtag(tag.toString(), num);
for (int i = 0, next_i; i < result.length(); i = next_i) { final int code_point = result.codePointAt(i); next_i = result.offsetByCodePoints(i, 1);
for (int i = idx; i < b.length();) { c = b.codePointAt(i); end = b.offsetByCodePoints(i, 1); switch (c) {
for (int i = 0, next_i; i < result.length(); i = next_i) { final int code_point = result.codePointAt(i); next_i = result.offsetByCodePoints(i, 1);
StringBuilder sb = new StringBuilder(str); while (true) { int end = sb.offsetByCodePoints(problem, 1); String decoded = sb.substring(problem, end); String encoded = " ".equals(decoded) ? "%20" : URLEncoder.encode(decoded, "UTF-8");
StringBuilder sb = new StringBuilder(str); while (true) { int end = sb.offsetByCodePoints(problem, 1); String decoded = sb.substring(problem, end); String encoded = " ".equals(decoded) ? "%20" : URLEncoder.encode(decoded, "UTF-8");
StringBuilder sb = new StringBuilder(str); while (true) { int end = sb.offsetByCodePoints(problem, 1); String decoded = sb.substring(problem, end); String encoded = " ".equals(decoded) ? "%20" : URLEncoder.encode(decoded, "UTF-8");
codeUnitIndex=dest.offsetByCodePoints(firstSupplementaryIndex, i-firstSupplementaryIndex);