* @draft ICU 54
* @provisional This API might change or be removed in a future release.
*/
- @Deprecated
public static int getSingleCodePoint(CharSequence s) {
if (s == null || s.length() == 0) {
return -1;
* @draft ICU 54
* @provisional This API might change or be removed in a future release.
*/
- @Deprecated
public static int compareCodePoint(int codePoint, CharSequence s) {
if (s == null) {
return 1;
public enum CountMethod {
/**
* Collapse spans. That is, modify/count the entire matching span as a single item, instead of separate
- * code points.
- *
+ * set elements.
+ *
* @draft ICU 54
* @provisional This is a draft API and might change in a future release of ICU.
*/
* <li>spanning with [{ab}] will count two MIN_ELEMENTS.</li>
* <li>spanning with [ab{ab}] will also count two MIN_ELEMENTS.</li>
* </ul>
- *
+ *
* @draft ICU 54
* @provisional This is a draft API and might change in a future release of ICU.
*/
* @param countMethod
* whether to treat an entire span as a match, or individual elements as matches
* @param spanCondition
- * the spanCondition to use. SIMPLE or CONTAINED means only count the code points in the span;
+ * the spanCondition to use. SIMPLE or CONTAINED means only count the elements in the span;
* NOT_CONTAINED is the reverse.
* <br><b>WARNING: </b> when a UnicodeSet contains strings, there may be unexpected behavior in edge cases.
* @return the count. Zero if there are none.
}
/**
- * Returns a trimmed sequence (using CharSequence.subsequence()), that omits matching code points at the start and
+ * Returns a trimmed sequence (using CharSequence.subsequence()), that omits matching elements at the start and
* end of the string, using TrimOption.BOTH and SpanCondition.SIMPLE. For example:
*
* <pre>
}
/**
- * Returns a trimmed sequence (using CharSequence.subsequence()), that omits matching code points at the start or
+ * Returns a trimmed sequence (using CharSequence.subsequence()), that omits matching elements at the start or
* end of the string, using the trimOption and SpanCondition.SIMPLE. For example:
*
* <pre>
}
/**
- * Returns a trimmed sequence (using CharSequence.subsequence()), that omits matching code points at the start or
+ * Returns a trimmed sequence (using CharSequence.subsequence()), that omits matching elements at the start or
* end of the string, depending on the trimOption and spanCondition. For example:
*
* <pre>