Package com.ibm.icu.text
Class CaseMap.Lower
- java.lang.Object
-
- com.ibm.icu.text.CaseMap
-
- com.ibm.icu.text.CaseMap.Lower
-
- Enclosing class:
- CaseMap
public static final class CaseMap.Lower extends CaseMap
Lowercasing options and methods. Immutable.- See Also:
CaseMap.toLower()
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from class com.ibm.icu.text.CaseMap
CaseMap.Fold, CaseMap.Lower, CaseMap.Title, CaseMap.Upper
-
-
Field Summary
Fields Modifier and Type Field Description private static CaseMap.Lower
DEFAULT
private static CaseMap.Lower
OMIT_UNCHANGED
-
Fields inherited from class com.ibm.icu.text.CaseMap
internalOptions
-
-
Constructor Summary
Constructors Modifier Constructor Description private
Lower(int opt)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description java.lang.String
apply(java.util.Locale locale, java.lang.CharSequence src)
Lowercases a string.<A extends java.lang.Appendable>
Aapply(java.util.Locale locale, java.lang.CharSequence src, A dest, Edits edits)
Lowercases a string and optionally records edits (seeomitUnchangedText()
).CaseMap.Lower
omitUnchangedText()
Returns an instance that behaves like this one but omits unchanged text when case-mapping withEdits
.
-
-
-
Field Detail
-
DEFAULT
private static final CaseMap.Lower DEFAULT
-
OMIT_UNCHANGED
private static final CaseMap.Lower OMIT_UNCHANGED
-
-
Method Detail
-
omitUnchangedText
public CaseMap.Lower omitUnchangedText()
Returns an instance that behaves like this one but omits unchanged text when case-mapping withEdits
.- Specified by:
omitUnchangedText
in classCaseMap
- Returns:
- an options object with this option.
-
apply
public java.lang.String apply(java.util.Locale locale, java.lang.CharSequence src)
Lowercases a string. Casing is locale-dependent and context-sensitive. The result may be longer or shorter than the original.- Parameters:
locale
- The locale ID. Can be null forLocale.getDefault()
. (SeeULocale.toLocale()
.)src
- The original string.- Returns:
- the result string.
- See Also:
UCharacter.toLowerCase(Locale, String)
-
apply
public <A extends java.lang.Appendable> A apply(java.util.Locale locale, java.lang.CharSequence src, A dest, Edits edits)
Lowercases a string and optionally records edits (seeomitUnchangedText()
). Casing is locale-dependent and context-sensitive. The result may be longer or shorter than the original.- Parameters:
locale
- The locale ID. Can be null forLocale.getDefault()
. (SeeULocale.toLocale()
.)src
- The original string.dest
- A buffer for the result string. Must not be null.edits
- Records edits for index mapping, working with styled text, and getting only changes (if any). This function calls edits.reset() first. edits can be null.- Returns:
- dest with the result string (or only changes) appended.
- See Also:
UCharacter.toLowerCase(Locale, String)
-
-