StringUtils extension

An extention on String with various useful functionality

Convertors such as toCamelCase (camelCase), toPascalCase (PascalCase) and toSnakeCase (snake_case). Trimmers such as rtrim & ltrim for right and left trim, respectively.
removeExtraSpace to remove any extra white spaces (>1) such as:

"  a    b   c   d   " => " a b c d "


isCamelCase bool
returns true if this is of camelCase pattern
no setter
isPascalCase bool
returns true if this is of PascalCasepattern
no setter
isSnakeCase bool
returns true if this is of snake_case pattern
no setter


ltrim() String
trims leading whitespace
removeExtraSpace() String
this will remove extra spaces (i.e., > 1 space in sequence);
rtrim() String
trims trailing whitespace
toCamelCase() String
toLowerFirst() String
toPascalCase() String
toSnakeCase() String
toUpperFirst() String