code: public static String asTitleCase(String text) {
          // special for _value, eg we want to let underscore be like a space
          text = text.replace('_', ' ');
  
          // remove double spaces
          text = text.replaceAll("\\s+", " ");
  
          // see: http://stackoverflow.com/questions/2559759/how-do-i-convert-camelcase-into-human-readable-names-in-java
          text = text.replaceAll(
                  String.format("%s|%s|%s",
                          "(?<=[A-Z])(?=[A-Z][a-z])",
                          "(?<=[^A-Z])(?=[A-Z])",
                          "(?<=[A-Za-z])(?=[^A-Za-z])"
                  ),
                  " "
          );
  
          return Character.toUpperCase(text.charAt(0)) + text.substring(1);
      }
docs: Returns the text in human readable title/camel case format