A selection of utility methods for accessing Unicode
information about Character
s and performing locale-aware
transformations on String
s:
uppercase()
and lowercase()
change the case of a
String
according to the rules of a certain locale,graphemes()
, words()
, and sentences()
allow
iteration of the Unicode graphemes, words, and sentences
in a String
, according to locale-specific rules,characterName()
returns the Unicode character name of
a character, andgeneralCategory()
and directionality()
return the
Unicode general category and directionality of a
Character
.Packages | |
ceylon.unicode |
Dependencies | ||
java.base | 7 |
Values | |
arabicNumber | Source Codeshared arabicNumber arabicNumber |
boundaryNeutral | Source Codeshared boundaryNeutral boundaryNeutral |
commonNumberSeparator | Source Codeshared commonNumberSeparator commonNumberSeparator |
europeanNumber | Source Codeshared europeanNumber europeanNumber |
europeanNumberSeparator | Source Codeshared europeanNumberSeparator europeanNumberSeparator |
europeanNumberTerminator | Source Codeshared europeanNumberTerminator europeanNumberTerminator |
leftToRight | Source Codeshared leftToRight leftToRight |
leftToRightEmbedding | Source Codeshared leftToRightEmbedding leftToRightEmbedding |
leftToRightOverride | Source Codeshared leftToRightOverride leftToRightOverride |
letterLowercase | Source Codeshared letterLowercase letterLowercase The General category for |
letterModifier | Source Codeshared letterModifier letterModifier The General category for |
letterOther | Source Codeshared letterOther letterOther The General category for |
letterTitlecase | Source Codeshared letterTitlecase letterTitlecase The General category for |
letterUppercase | Source Codeshared letterUppercase letterUppercase The General category for |
markCombiningSpacing | Source Codeshared markCombiningSpacing markCombiningSpacing The General category for |
markEnclosing | Source Codeshared markEnclosing markEnclosing The General category for |
markNonspacing | Source Codeshared markNonspacing markNonspacing The General category for |
nonspacingMark | Source Codeshared nonspacingMark nonspacingMark |
numberDecimalDigit | Source Codeshared numberDecimalDigit numberDecimalDigit The General category for |
numberLetter | Source Codeshared numberLetter numberLetter The General category for |
numberOther | Source Codeshared numberOther numberOther The General category for |
otherControl | Source Codeshared otherControl otherControl The General category for |
otherFormat | Source Codeshared otherFormat otherFormat The General category for |
otherNeutrals | Source Codeshared otherNeutrals otherNeutrals |
otherPrivateUse | Source Codeshared otherPrivateUse otherPrivateUse The General category for |
otherSurrogate | Source Codeshared otherSurrogate otherSurrogate The General category for |
otherUnassigned | Source Codeshared otherUnassigned otherUnassigned The General category for |
paragraphSeparator | Source Codeshared paragraphSeparator paragraphSeparator |
popDirectionalFormat | Source Codeshared popDirectionalFormat popDirectionalFormat |
punctuationClose | Source Codeshared punctuationClose punctuationClose The General category for |
punctuationConnector | Source Codeshared punctuationConnector punctuationConnector The General category for |
punctuationDash | Source Codeshared punctuationDash punctuationDash The General category for |
punctuationFinalQuote | Source Codeshared punctuationFinalQuote punctuationFinalQuote The General category for |
punctuationInitialQuote | Source Codeshared punctuationInitialQuote punctuationInitialQuote The General category for |
punctuationOpen | Source Codeshared punctuationOpen punctuationOpen The General category for |
punctuationOther | Source Codeshared punctuationOther punctuationOther The General category for |
rightToLeft | Source Codeshared rightToLeft rightToLeft |
rightToLeftArabic | Source Codeshared rightToLeftArabic rightToLeftArabic |
rightToLeftEmbedding | Source Codeshared rightToLeftEmbedding rightToLeftEmbedding |
rightToLeftOverride | Source Codeshared rightToLeftOverride rightToLeftOverride |
segmentSeparator | Source Codeshared segmentSeparator segmentSeparator |
separatorLine | Source Codeshared separatorLine separatorLine The General category for |
separatorParagraph | Source Codeshared separatorParagraph separatorParagraph The General category for |
separatorSpace | Source Codeshared separatorSpace separatorSpace The General category for |
symbolCurrency | Source Codeshared symbolCurrency symbolCurrency The General category for |
symbolMath | Source Codeshared symbolMath symbolMath The General category for |
symbolModifier | Source Codeshared symbolModifier symbolModifier The General category for |
symbolOther | Source Codeshared symbolOther symbolOther The General category for |
undefined | Source Codeshared undefined undefined |
unicodeVersion | Source Codeshared String? unicodeVersion The version of the Unicode standard being used, or |
whitespace | Source Codeshared whitespace whitespace |
Functions | |
assigned | Source Codeshared Boolean assigned(Integer codePoint) Determine if the given integer code point is assigned a Unicode character. |
characterName | Source Codeshared String characterName(Character character) The Unicode name of the given character. |
directionality | Source Codeshared Directionality directionality(Character character) The directionality of the given character. |
generalCategory | Source Codeshared GeneralCategory generalCategory(Character character) The general category of the given character. |
graphemes | Source Codeshared {String*} graphemes(String text, String tag = ...) The graphemes contained in the given string. In
general, a Unicode Parameters:
|
lowercase | Source Codeshared String lowercase(String string, String tag = ...) Convert the given Parameters:
|
privateUse | Source Codeshared Boolean privateUse(Integer codePoint) Determine if the given integer code point is belongs to a Unicode Private Use Area. |
sentences | Source Codeshared {String*} sentences(String text, String tag = ...) The sentences contained in the given string, according to the rules of the given locale. Whitespace is trimmed from the beginning and end of each sentence, but whitespace contained within the sentence is not normalized. Parameters:
|
uppercase | Source Codeshared String uppercase(String string, String tag = ...) Convert the given Parameters:
|
words | Source Codeshared {String*} words(String text, String tag = ...) The words and punctuation contained in the given string, according to the rules of the given locale. Any non-whitespace character not contained in a word is treated as a whole word. All whitespace characters are discarded. Parameters:
|