Package com.yahoo.text
Class UnicodeString
java.lang.Object
com.yahoo.text.UnicodeString
A string wrapper with some convenience methods for dealing with UTF-16 surrogate pairs (a crime against humanity).
- Author:
- bratseth
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionintcodePointAt(int index) intReturns the number of code points in thisbooleaninthashCode()intlength()Returns the number of positions (not code points) in thisintnextCodePoint(int index) Returns the code point at the next position after the given index, or if the index is at the last code pointintnextIndex(int index) Returns the index of the next code point after the given index (which may be past the end of the string)intskip(int codePointCount, int start) Returns the position count code points after start (which may be past the end of the string)substring(int start, int codePoints) Substring in code point spacetoString()
-
Constructor Details
-
UnicodeString
-
-
Method Details
-
substring
Substring in code point space -
skip
public int skip(int codePointCount, int start) Returns the position count code points after start (which may be past the end of the string) -
nextIndex
public int nextIndex(int index) Returns the index of the next code point after the given index (which may be past the end of the string) -
nextCodePoint
public int nextCodePoint(int index) Returns the code point at the next position after the given index, or if the index is at the last code point -
length
public int length()Returns the number of positions (not code points) in this -
codePointCount
public int codePointCount()Returns the number of code points in this -
codePointAt
public int codePointAt(int index) -
toString
-
equals
-
hashCode
public int hashCode()
-