An instance of class UCA defines a sort order, but it also holds options and state for getSortKey() and other functions. This makes the code fragile and hard to reason about.
Try to split it so that we get an immutable sort order class and one or more worker classes.
Bonus: See if any callers use an AppendToCe other than AppendToCe.none with strength < quaternary. If not, combine AppendToCe into the strength option.
An instance of class UCA defines a sort order, but it also holds options and state for getSortKey() and other functions. This makes the code fragile and hard to reason about.
Try to split it so that we get an immutable sort order class and one or more worker classes.
Bonus: See if any callers use an AppendToCe other than AppendToCe.none with strength < quaternary. If not, combine AppendToCe into the strength option.