speters33w opened a new pull request, #528:
URL: https://github.com/apache/commons-text/pull/528
This adds several methods to CaseUtils, that allow a user to convert a
string to a variety of cases. These methods normalize the strings to ANSI Latin.
I've created new tests from the existing tests for `toCamelCase(String,
boolean, char[])` and run them, all the output is as expected.
The main driver engine for the new methods is in toTitleCase().
This is what you get...
```
* "Two words" "foo bar" "Piñata Café"
* toCamelCase(str) "twoWords" "fooBar" "pinataCafe"
* toCamelCase(str, false, " ") "twoWords" "fooBar" "piñataCafé"
* toCamelCase(str, true, " ") "TwoWords" "FooBar" "PiñataCafé"
* ToCamelSnakeCase "two_Words" "foo_Bar" "pinata_Cafe"
* toFlatcase(str) "twowords" "foobar" "pinatacafe"
* toKebabCase(str) "two-words" "foo-bar" "pinata-cafe"
* toScreamingCase(str) "TWOWORDS" "FOOBAR" "PINATACAFE"
* toScreamingKebabCase(str) "TWO-WORDS" "FOO-BAR" "PINATA-CAFE"
* toScreamingSnakeCase(str) "TWO_WORDS" "FOO_BAR" "PINATA_CAFE"
* toSnakeCase(str) "two_words" "foo_bar" "pinata_cafe"
* toTitleCase(str) "Two_Words" "Foo_Bar" "Pinata_Cafe"
* toTrainCase(str) "Two-Words" "Foo-Bar" "Pinata-Cafe"
* toUpperCamelCase(str) "TwoWords" "FooBar" "PinataCafe"
```
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]