Package com.ibm.icu.text
Class CaseMap.Fold
- java.lang.Object
-
- com.ibm.icu.text.CaseMap
-
- com.ibm.icu.text.CaseMap.Fold
-
- Enclosing class:
- CaseMap
public static final class CaseMap.Fold extends CaseMap
Case folding options and methods. Immutable.- See Also:
CaseMap.fold()
-
-
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 inherited from class com.ibm.icu.text.CaseMap
internalOptions
-
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description String
apply(CharSequence src)
Case-folds a string.<A extends Appendable>
Aapply(CharSequence src, A dest, Edits edits)
Case-folds a string and optionally records edits (seeomitUnchangedText()
).CaseMap.Fold
omitUnchangedText()
Returns an instance that behaves like this one but omits unchanged text when case-mapping withEdits
.CaseMap.Fold
turkic()
Returns an instance that behaves like this one but handles dotted I and dotless i appropriately for Turkic languages (tr, az).
-
-
-
Method Detail
-
omitUnchangedText
public CaseMap.Fold 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.
-
turkic
public CaseMap.Fold turkic()
Returns an instance that behaves like this one but handles dotted I and dotless i appropriately for Turkic languages (tr, az).Uses the Unicode CaseFolding.txt mappings marked with 'T' that are to be excluded for default mappings and included for the Turkic-specific mappings.
- Returns:
- an options object with this option.
- See Also:
UCharacter.FOLD_CASE_EXCLUDE_SPECIAL_I
-
apply
public String apply(CharSequence src)
Case-folds a string. The result may be longer or shorter than the original.Case-folding is locale-independent and not context-sensitive, but there is an option for whether to include or exclude mappings for dotted I and dotless i that are marked with 'T' in CaseFolding.txt.
- Parameters:
src
- The original string.- Returns:
- the result string.
- See Also:
UCharacter.foldCase(String, int)
-
apply
public <A extends Appendable> A apply(CharSequence src, A dest, Edits edits)
Case-folds a string and optionally records edits (seeomitUnchangedText()
). The result may be longer or shorter than the original.Case-folding is locale-independent and not context-sensitive, but there is an option for whether to include or exclude mappings for dotted I and dotless i that are marked with 'T' in CaseFolding.txt.
- Parameters:
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.foldCase(String, int)
-
-