@Nullable public static String capitalize(@Nullable final String string){
  if (isBlank(string)) {
    return string;
  }
  final char firstChar=string.charAt(0);
  final char newChar=Character.toUpperCase(firstChar);
  if (firstChar == newChar) {
    return string;
  }
  int strLen=string.length();
  char[] newChars=new char[strLen];
  newChars[0]=newChar;
  string.getChars(1,strLen,newChars,1);
  return String.valueOf(newChars);
}

@ Nullable public static String capitalize ( @ Nullable final String string ) { if ( isBlank ( string ) ) { return string ; } final char firstChar = string . charAt ( 0 ) ; final char newChar = Character . toUpperCase ( firstChar ) ; if ( firstChar == newChar ) { return string ; } int strLen = string . length ( ) ; char [ ] newChars = new char [ strLen ] ; newChars [ 0 ] = newChar ; string . getChars ( 1 , strLen , newChars , 1 ) ; return String . valueOf ( newChars ) ; }
capitalizes a string changing the first letter to title case
