mirror of
https://github.com/openjdk/jdk.git
synced 2026-01-28 12:09:14 +00:00
Improve JavaDoc
Co-authored-by: Chen Liang <liach@openjdk.org>
This commit is contained in:
parent
0e55e35c5a
commit
4744ee694e
@ -530,12 +530,7 @@ abstract sealed class AbstractStringBuilder implements Appendable, CharSequence
|
||||
}
|
||||
|
||||
/**
|
||||
* Returns the number of Unicode code points in
|
||||
* this sequence. Unpaired surrogates count
|
||||
* as one code point each.
|
||||
*
|
||||
* @return the number of Unicode code points in this String
|
||||
* @since 26
|
||||
* @since 27
|
||||
*/
|
||||
public int codePointCount() {
|
||||
byte coder = this.coder;
|
||||
|
||||
@ -254,12 +254,10 @@ public interface CharSequence {
|
||||
}
|
||||
|
||||
/**
|
||||
* Returns the number of Unicode code points in
|
||||
* this sequence. Unpaired surrogates count
|
||||
* as one code point each.
|
||||
* {@return the number of Unicode code points in this character sequence}
|
||||
* Unpaired surrogates count as one code point each.
|
||||
*
|
||||
* @return the number of Unicode code points in this sequence
|
||||
* @since 26
|
||||
* @since 27
|
||||
*/
|
||||
public default int codePointCount() {
|
||||
final int length = length();
|
||||
|
||||
@ -10000,14 +10000,12 @@ class Character implements java.io.Serializable, Comparable<Character>, Constabl
|
||||
}
|
||||
|
||||
/**
|
||||
* Returns the number of Unicode code points in the
|
||||
* {@code char} array argument. Unpaired
|
||||
* surrogates count as one code point each.
|
||||
* {@return the number of Unicode code points in the {@code char} array}
|
||||
* Unpaired surrogates count as one code point each.
|
||||
*
|
||||
* @param a the {@code char} array
|
||||
* @return the number of Unicode code points in the char array
|
||||
* @throws NullPointerException if {@code a} is null.
|
||||
* @since 26
|
||||
* @throws NullPointerException if {@code a} is null
|
||||
* @since 27
|
||||
*/
|
||||
public static int codePointCount(char[] a) {
|
||||
return codePointCountImpl(a, 0, a.length);
|
||||
|
||||
@ -1715,12 +1715,10 @@ public final class String
|
||||
}
|
||||
|
||||
/**
|
||||
* Returns the number of Unicode code points in
|
||||
* this {@code String}. Unpaired surrogates count
|
||||
* as one code point each.
|
||||
* {@return the number of Unicode code points in this String}
|
||||
* Unpaired surrogates count as one code point each.
|
||||
*
|
||||
* @return the number of Unicode code points in this String
|
||||
* @since 26
|
||||
* @since 27
|
||||
*/
|
||||
public int codePointCount() {
|
||||
if (isLatin1()) {
|
||||
|
||||
@ -271,7 +271,7 @@ import jdk.internal.vm.annotation.IntrinsicCandidate;
|
||||
}
|
||||
|
||||
/**
|
||||
* @since 26
|
||||
* @since 27
|
||||
*/
|
||||
@Override
|
||||
public synchronized int codePointCount() {
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user