The input string to be processed.
A boolean flag indicating whether to convert the rest of the string to lowercase.
If true
, the remaining characters (after the first) will be converted to lowercase.
If false
, the remaining characters will remain unchanged.
A new string with the first character capitalized and the rest lowercased if the lowerCaseRest
flag is true
.
If the lowerCaseRest
flag is false
, only the first character is capitalized, and the rest of the string remains unchanged.
Capitalizes the first character of a string and optionally lowercases the rest of the string.