6

There is convenient method StringUtils.capitalize() in apache-commons-lang library. But I can not find pairwise inverse method for it, which will make first letter in word in lowercase. Does such method exists?

Denys
  • 133
  • 2
  • 7
  • @JeroenVannevel I don't agree with you: there are situations where it would be nice to have translation from "AbcAbc" to "abcAbc", for example, in code generation tasks – Andremoniy Mar 31 '15 at 15:32

1 Answers1

9

You're looking for StringUtils.uncapitalize:

Uncapitalizes a String changing the first letter to title case as per Character.toLowerCase(char). No other letters are changed.

M A
  • 71,713
  • 13
  • 134
  • 174